Skip to content
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

Targets depending on industrial_robot_client link with both swap and non-swap libraries #10

Closed
gavanderhoorn opened this issue Jun 4, 2013 · 5 comments
Assignees
Labels
Milestone

Comments

@gavanderhoorn
Copy link
Member

Seems to be due to the catkin_package(... LIBRARIES ..) statement in the CMakeLists.txt for industrial_robot_client.

simple_message has a similar problem, resulting in one target linking with both libsimple_message.so and libsimple_message_bswap.so.

@shaun-edwards
Copy link
Member

This seems like the linker would complain about multiple definitions of the same functions/classes. Is this not the case. The port from rosbuild to catkin was not straightforward for these libraries. It's probably worth going back to the rosbuild versions and finding the right catkin equivalent. I'm not sure how to label this? Does this break anything or is it something we can live with?

@gavanderhoorn
Copy link
Member Author

re: multiple definitions: I haven't seen any errors, but the resulting binaries show both the non-swap and the swap versions of the libraries in their ldd output.

As for a solution: the rosbuild CMakeLists.txt avoid exporting any libraries, and have a comment explaining that dependent packages should explicitly link the version they require. The binaries in the fanuc_common package do exactly that.

Perhaps not listing the libraries in the catkin_package(..) statement and keeping that comment would be a viable solution? Not sure if catkin has any more sophisticated mechanisms in place for these kind of things.

@ghost ghost assigned jrgnicho Jul 24, 2013
@shaun-edwards
Copy link
Member

The way we link to specific libraries in rosbuild was non-standard. In fact, the convention is that a package exports a single library. Because we cannot follow this convention, we specifically identify the library we want to link against. It would be nice to do something similar in catkin (I think this is what gavanderhoorn is alluding to in his comment above).

@gavanderhoorn
Copy link
Member Author

@shaun-edwards: yes, I was refering to the way we did things with rosbuild. I currently don't link against catkin_LIBRARIES for that reason in the CMakeLists.txt of the fanuc_driver, but explicitly reference the proper libraries. This has worked for me.

@shaun-edwards
Copy link
Member

Issued fixed by merged pull request

Jmeyer1292 pushed a commit to Jmeyer1292/industrial_core that referenced this issue Feb 14, 2017
Fix ros-industrial#10: Update abb_moveit_plugins for compatibility with latest MoveIt API
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

3 participants