Universal_Robots_ROS_Driver icon indicating copy to clipboard operation
Universal_Robots_ROS_Driver copied to clipboard

Fix compile erros when using RoboStack (conda)

Open nberliner opened this issue 4 years ago • 8 comments

The RoboStack maintainers helped to fix compile errors when building the UR drivers using a conda environment. conda is, in my humble opinion, very useful and the suggested changes might be helpful for others.

For more information, please see RoboStack/ros-noetic#155 and RoboStack/ros-noetic#157 .

nberliner avatar Aug 13 '21 14:08 nberliner

This seems unusual at first.

The console_bridge issues should probably be gone with https://github.com/UniversalRobots/Universal_Robots_Client_Library/pull/74 merged.

As for the -D__STDC_FORMAT_MACROS definition: Why is this necessary?

fmauch avatar Aug 16 '21 09:08 fmauch

Hi, thanks for having a look. To be honest, I don't know what -D__STDC_FORMAT_MACROS does or why it is necessary. It was suggested to me by the maintainer of RoboStack here.

Maybe you could chime in on RoboStack/ros-noetic#157 to check where this fits best?

nberliner avatar Aug 16 '21 10:08 nberliner

@fmauch wrote:

As for the -D__STDC_FORMAT_MACROS definition: Why is this necessary?

From How to printf uint64_t? Fails with: “spurious trailing ‘%’ in format”:

The ISO C99 standard specifies that these macros must only be defined if explicitly requested.

#define __STDC_FORMAT_MACROS
#include <inttypes.h>

... now PRIu64 will work

gavanderhoorn avatar Aug 16 '21 10:08 gavanderhoorn

Thanks @gavanderhoorn

From my point of view none of the changes here should then be necessary with the latest versions.

@nberliner could you try building the driver without the changes with the latest library version (master or boost branch) and the latest master of this driver?

See the README about building the library from source, as well.

fmauch avatar Aug 16 '21 16:08 fmauch

I've tried to build the driver as well as ur_client_library from source. Unfortunately, building the ur_client_library within the RoboStack conda environment seems to be rather complicated (see here) and catkin_make_isolated failed. I probably need to wait until the RoboStack maintainers include the updates.

Please feel free to close this PR, it's definitely beyond my expertise.

Thanks for looking into it :)

nberliner avatar Aug 18 '21 09:08 nberliner

This PR hasn't made any progress for quite some time and will be closed soon. Please comment if it is still relevant.

github-actions[bot] avatar Apr 01 '23 22:04 github-actions[bot]

I should have a look at this again, before closing this.

fmauch avatar Apr 11 '23 11:04 fmauch

This PR hasn't made any progress for quite some time and will be closed soon. Please comment if it is still relevant.

github-actions[bot] avatar Jul 11 '23 22:07 github-actions[bot]