ros_gz icon indicating copy to clipboard operation
ros_gz copied to clipboard

Build Failure on Ubuntu 22.04 with Protobuf Error

Open aadith-warrier opened this issue 2 months ago • 3 comments

Environment

  • OS Version: Ubuntu 22.04
  • Source or binary build? Source build, humble branch

Description

  • Expected behaviour: Successful build
  • Actual behaviour: Build fails with (what I think is) a protobuf error

Steps to reproduce

  1. Create workspace
  2. Update rosdep keys from https://github.com/osrf/osrf-rosdep, and install dependencies via rosdep
  3. Run a colcon build

Output

Starting >>> ros_gz_interfaces
Finished <<< ros_gz_interfaces [58.4s]                        
Starting >>> ros_gz_sim
Finished <<< ros_gz_sim [24.0s]                             
Starting >>> ros_gz_bridge
--- stderr: ros_gz_bridge                                          
/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libprotobuf.a(arena.o): relocation R_X86_64_TPOFF32 against symbol `_ZN6google8protobuf8internal9ArenaImpl13thread_cache_E' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: failed to set dynamic section sizes: bad value
collect2: error: ld returned 1 exit status
gmake[2]: *** [CMakeFiles/ros_gz_bridge.dir/build.make:936: libros_gz_bridge.so] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:183: CMakeFiles/ros_gz_bridge.dir/all] Error 2
gmake: *** [Makefile:146: all] Error 2
---
Failed   <<< ros_gz_bridge [4min 49s, exited with code 2]

Summary: 2 packages finished [6min 12s]
  1 package failed: ros_gz_bridge
  1 package had stderr output: ros_gz_bridge
  10 packages not processed

aadith-warrier avatar May 02 '24 17:05 aadith-warrier