Build fails with rosbuild after fuerte

Issue #12 resolved
aggiejesus
created an issue

When building the multisense_ros drivers with rosbuild (rather than catkin) in ROS hydro, the build fails because the build configuration tries to use parameter_generator_catkin.py rather than the rosbuild-compatible parameter_generator.py.

The error is found in the python script multisense_ros/cfg/multisense.cfg, at lines 6-9. The script checks whether or not the ROS version is fuerte, rather than checking whether the build_system set by config.sh is catkin or rosbuild. Changing these lines to import the non-catkin parameter_generator allows the build to complete successfully with rosbuild.

The relevant build error message is below:

MSG: gencfg_cpp on:multisense.cfg ERROR [gendeps] 1 Finding dependencies for /home/user/workspace/multisense/multisense_ros/cfg/multisense.cfg


load_module did not return. Unable to determine dependencies for file listed above.


Traceback (most recent call last): File "/opt/ros/hydro/share/dynamic_reconfigure/cmake/gendeps", line 66, in <module> imp.load_module("main", f, srcfile, ('.cfg', 'U', 1)) File "/home/user/workspace/multisense/multisense_ros/cfg/multisense.cfg", line 28, in <module> gen = ParameterGenerator() File "/opt/ros/hydro/lib/python2.7/dist-packages/dynamic_reconfigure/parameter_generator_catkin.py", line 237, in init self.binary_dir = sys.argv[2] IndexError: list index out of range

CMake Error at /opt/ros/hydro/share/dynamic_reconfigure/cmake/cfgbuild.cmake:78 (string): string sub-command REPLACE requires at least four arguments. Call Stack (most recent call first): /opt/ros/hydro/share/dynamic_reconfigure/cmake/cfgbuild.cmake:99 (gencfg_cpp) CMakeLists.txt:20 (include)

Comments (3)

  1. David LaRose

    Thanks for the catch. A fix that works with both rosbuild and catkin would be to change:

    if os.environ['ROS_DISTRO'] == "fuerte":
    

    to read

    if os.path.isfile('../../stack.xml'):
    

    The "stack.xml" file only exists when the repository is configured for rosbuild. This fix will be in the next update.

  2. Log in to comment