Ask Your Question
2

Install a package parallel to /opt/ros

asked 2019-02-26 16:45:44 -0500

venkisagunner gravatar image

I have a custom package that I built. I ran bloom-generate rosdebian on the package and generated a debian folder. When I looked into debian/rules, I saw the following,

-DCMAKE_INSTALL_PREFIX="/opt/ros/melodic" \
-DCMAKE_PREFIX_PATH="/opt/ros/melodic"

I want to install my package to a location something like /opt/custom/melodic. These are the steps I'm following right now. Currently, I clone the package, run the following commands to generate a binary. I'm resolving the dependencies with a python script I custom brewed.

bloom-generate rosdebian
dpkg-buildpackage -b -us -uc

When the binary is installed, it gets installed into /opt/ros/melodic. Help much appreciated. Thanks !

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-02-27 08:37:09 -0500

VictorLamoine gravatar image

updated 2020-06-03 08:26:40 -0500

130s gravatar image

It looks like it's not possible to modify the installation prefix with the rosdebiangenerator (but you can try method below just to make sure): https://github.com/ros-infrastructure...

But with the debian generator you can choose what is going to be the installation prefix with the --install-prefix: bloom/generators/debian/generator.py (update 20200603 by @130s permalink)

However the help command does not seem to be up to date:

$ bloom-generate debian --help
usage: bloom-generate debian [-h]
                             [--place-template-files | --process-template-files]
                             [--os-name OS_NAME] [--os-version OS_VERSION]
                             [--ros-distro ROS_DISTRO] [--native] [-d]
                             [--version] [--unsafe]
                             [package_path]

Generates debian packaging files for a catkin package

positional arguments:
  package_path          path to or containing the package.xml of a package

optional arguments:
  -h, --help            show this help message and exit
  --place-template-files
                        places debian/* template files only
  --process-template-files
                        processes templates in debian/* only
  --os-name OS_NAME     OS name, e.g. ubuntu, debian
  --os-version OS_VERSION
                        OS version or codename, e.g. precise, wheezy
  --ros-distro ROS_DISTRO
                        ROS distro, e.g. indigo, kinetic, lunar, melodic (used
                        for rosdep)
  --native              generate native package

global:
  -d, --debug           enable debug messages
  --version             prints the bloom version
  --unsafe              Makes bloom faster, but if there is an error then you
                        could run into trouble.
edit flag offensive delete link more

Comments

I've opened an issue because I think the documentation is incomplete: https://github.com/ros-infrastructure...

VictorLamoine gravatar image VictorLamoine  ( 2019-02-27 08:43:52 -0500 )edit

It didnt work. I guess, there is capability to change the prefix path as you mentioned but the front end doesnt support that.

venkisagunner gravatar image venkisagunner  ( 2019-02-27 14:05:33 -0500 )edit
1

As a last resort you can still tweak the debian/rules using sed.

VictorLamoine gravatar image VictorLamoine  ( 2019-02-28 03:56:21 -0500 )edit

Nice info! I just found a follow-up https://github.com/ros-infrastructure... clarifying that in order to utilize --install-prefixgit-bloom-generate should be used (which has different args and contexts so exact same args and flow doesn't work though).

130s gravatar image 130s  ( 2020-06-03 08:44:19 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2019-02-26 16:45:44 -0500

Seen: 560 times

Last updated: Jun 03 '20