Skip to content

Using ROS 2 dependencies #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 19, 2024
Merged

Using ROS 2 dependencies #1

merged 2 commits into from
Jul 19, 2024

Conversation

marcbone
Copy link
Member

With this PR you can compile xbot2_interface with ROS 2 dependencies.

Install instructions:

sudo apt install -y libboost-all-dev ros-humble-srdfdom ros-humble-pinocchio ros-humble-tf2-eigen-kdl ros-humble-hpp-fcl ros-humble-geometric-shapes ros-humble-moveit-core

mkdir build
cd build
source /opt/ros/humble/setup.bash
cmake .. -DCMAKE_BUILD_TYPE=Release 
make -j16
cpack -G DEB
sudo dpkg -i *.deb

@marcbone marcbone requested a review from Pouya-moh July 15, 2024 13:39
@Pouya-moh
Copy link

If I run this I get cmake warnings for pinocchio

CMake Warning at pinocchio/CMakeLists.txt:3 (add_library):
  Cannot generate a safe runtime search path for target modelinterface2_pin
  because files in some directories may conflict with libraries in implicit
  directories:

    runtime library [liburdfdom_sensor.so.3.0] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /opt/ros/humble/lib/x86_64-linux-gnu
    runtime library [liburdfdom_model_state.so.3.0] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /opt/ros/humble/lib/x86_64-linux-gnu
    runtime library [liburdfdom_model.so.3.0] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /opt/ros/humble/lib/x86_64-linux-gnu
    runtime library [liburdfdom_world.so.3.0] in /usr/lib/x86_64-linux-gnu may be hidden by files in:
      /opt/ros/humble/lib/x86_64-linux-gnu

  Some of these libraries may not be found correctly.

But bigger problem is as follows:

  • I ignore the cmake warning and made the package
  • now if I run the camke again or try to do make install this raise an error.

I this normal behaviour?

Copy link

@Pouya-moh Pouya-moh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR seems to be working, however, there is one issue which we need to tackle in some point in the future. See the comment made in this PR for reference. Please do NOT delete the branch after merge.

@Pouya-moh
Copy link

There seems to be a bug related to cmake, python or our PR. To replicate, simply do the following:

cd /tmp
git clone -b ros2-deps https://github.com/Gauss-Robotics/xbot2_interface.git
cd xbot2_interface
mkdir build && cd build
cmake .. 

This will work with some warnings, however, if you try

cmake ..

again, it will fail. See this gist.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants