Issue #2600 resolved
Rich Mattes
created an issue

Gazebo's pkg-config LIBS field contains a placeholder for @Boost_PKGCONFIG_LIBS@. That CMake variable is assembled in the root CMakeLists.txt, with some string processing that unconditionally prepends -l to each entry in Boost_LIBRARIES.

In Fedora 30, the Boost_LIBRARIES CMake variable contains -lpthread in addition to the absolute paths to the required boost libraries. The string processing in CMakeLists.txt adds an additional -l in front of it, resulting in -l-lpthread being added to the LIBS line. Fedora 30 has Boost 1.69.0, and CMake 3.13.4

This patch works around the issue by checking each string to see if -l is already pre-pended to the string. There's probably some extra thought that can be put into this section, such as only eliminating lib from the front of the library name, and performing no additional processing if -l is detected, but the referenced patch is enough to work around the Fedora 30 issue.

Comments (8)

  1. Log in to comment