Skip to content

Fix finding of Thread libraries.#12

Open
clalancette wants to merge 1 commit into
stonier:develfrom
clalancette:clalancette/fix-find-threads
Open

Fix finding of Thread libraries.#12
clalancette wants to merge 1 commit into
stonier:develfrom
clalancette:clalancette/fix-find-threads

Conversation

@clalancette
Copy link
Copy Markdown

Instead of include(FindThreads), use find_package(Threads), which is the correct way to do this. This removes a warning when using this with CMake >= 3.24.

Signed-off-by: Chris Lalancette clalancette@openrobotics.org

This will get rid of warnings that look like:

CMake Warning (dev) at /usr/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (Threads)
  does not match the name of the calling package (ecl_threads).  This can
  lead to problems in calling code that expects `find_package` result
  variables (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  /usr/share/cmake-3.22/Modules/FindThreads.cmake:238 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  /home/ubuntu/kobuki_ws/install/ecl_build/share/ecl_build/cmake/ecl_platform_detection.cmake:225 (include)
  /home/ubuntu/kobuki_ws/install/ecl_threads/share/ecl_threads/cmake/ecl_threads-extras.cmake:4 (ecl_detect_threads)
  /home/ubuntu/kobuki_ws/install/ecl_threads/share/ecl_threads/cmake/ecl_threadsConfig.cmake:41 (include)
  CMakeLists.txt:19 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

And should fix stonier/ecl_core#106 . @stonier FYI.

Instead of include(FindThreads), use find_package(Threads), which
is the correct way to do this.  This removes a warning when
using this with CMake >= 3.24.

Signed-off-by: Chris Lalancette <clalancette@openrobotics.org>
@clalancette
Copy link
Copy Markdown
Author

Friendly ping on this one @stonier. Would be great to get this in.

@clalancette
Copy link
Copy Markdown
Author

@stonier Another friendly ping on this one. If we merge in this and stonier/sophus#23, we can then release the kobuki nodes into Humble and Iron.

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.

Build warning for threads

1 participant