From 724e5f12fbe1745dc681edfce3a55c2c29c9f0a6 Mon Sep 17 00:00:00 2001 From: Roelof Oomen Date: Thu, 11 Jul 2024 17:53:15 +0200 Subject: [PATCH] Fixes for building on Ubuntu Noble (#1016) --- tesseract_common/test/plugin_loader_unit.cpp | 5 +++-- tesseract_environment/CMakeLists.txt | 2 +- tesseract_kinematics/CMakeLists.txt | 2 +- tesseract_state_solver/CMakeLists.txt | 2 +- tesseract_urdf/CMakeLists.txt | 4 ++-- tesseract_visualization/CMakeLists.txt | 2 +- 6 files changed, 9 insertions(+), 8 deletions(-) diff --git a/tesseract_common/test/plugin_loader_unit.cpp b/tesseract_common/test/plugin_loader_unit.cpp index fb880648bf6..e6facbe084c 100644 --- a/tesseract_common/test/plugin_loader_unit.cpp +++ b/tesseract_common/test/plugin_loader_unit.cpp @@ -82,8 +82,8 @@ TEST(TesseractClassLoaderUnit, LoadTestPlugin) // NOLINT // For some reason on Ubuntu 18.04 it does not search the current directory when only the library name is provided #if BOOST_VERSION > 106800 && !__APPLE__ { - EXPECT_TRUE(ClassLoader::isClassAvailable(symbol_name, lib_name)); - auto plugin = ClassLoader::createSharedInstance(symbol_name, lib_name); + EXPECT_TRUE(ClassLoader::isClassAvailable(symbol_name, lib_name, ".")); + auto plugin = ClassLoader::createSharedInstance(symbol_name, lib_name, "."); EXPECT_TRUE(plugin != nullptr); EXPECT_NEAR(plugin->multiply(5, 5), 25, 1e-8); } @@ -150,6 +150,7 @@ TEST(TesseractPluginLoaderUnit, LoadTestPlugin) // NOLINT #if BOOST_VERSION > 106800 && !__APPLE__ { PluginLoader plugin_loader; + plugin_loader.search_paths.insert("."); plugin_loader.search_libraries.insert("tesseract_common_test_plugin_multiply"); EXPECT_TRUE(plugin_loader.isPluginAvailable("plugin")); diff --git a/tesseract_environment/CMakeLists.txt b/tesseract_environment/CMakeLists.txt index dc01a4b4a99..1207d43d66a 100644 --- a/tesseract_environment/CMakeLists.txt +++ b/tesseract_environment/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.15.0) # Extract package name and version find_package(ros_industrial_cmake_boilerplate REQUIRED) extract_package_metadata(pkg) -project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES CXX) +project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES C CXX) if(WIN32) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) diff --git a/tesseract_kinematics/CMakeLists.txt b/tesseract_kinematics/CMakeLists.txt index 6c2f3b747c8..a72b68e30b5 100644 --- a/tesseract_kinematics/CMakeLists.txt +++ b/tesseract_kinematics/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.15.0) # Extract package name and version find_package(ros_industrial_cmake_boilerplate REQUIRED) extract_package_metadata(pkg) -project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES CXX) +project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES C CXX) if(WIN32) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) diff --git a/tesseract_state_solver/CMakeLists.txt b/tesseract_state_solver/CMakeLists.txt index ede7f1f325c..6336cdb6ae0 100644 --- a/tesseract_state_solver/CMakeLists.txt +++ b/tesseract_state_solver/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.15.0) # Extract package name and version find_package(ros_industrial_cmake_boilerplate REQUIRED) extract_package_metadata(pkg) -project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES CXX) +project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES C CXX) if(WIN32) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) diff --git a/tesseract_urdf/CMakeLists.txt b/tesseract_urdf/CMakeLists.txt index 815baf0d5e3..1a6f1c358f5 100644 --- a/tesseract_urdf/CMakeLists.txt +++ b/tesseract_urdf/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.15.0) # Extract package name and version find_package(ros_industrial_cmake_boilerplate REQUIRED) extract_package_metadata(pkg) -project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES CXX) +project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES C CXX) if(WIN32) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) @@ -12,7 +12,7 @@ endif() find_package(Boost REQUIRED) find_package(Eigen3 REQUIRED) find_package(console_bridge REQUIRED) -find_package(PCL REQUIRED COMPONENTS common io) +find_package(PCL REQUIRED COMPONENTS io) find_package(tesseract_geometry REQUIRED) find_package(tesseract_common REQUIRED) find_package(tesseract_scene_graph REQUIRED) diff --git a/tesseract_visualization/CMakeLists.txt b/tesseract_visualization/CMakeLists.txt index db2db8c1224..64c72281187 100644 --- a/tesseract_visualization/CMakeLists.txt +++ b/tesseract_visualization/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.15.0) # Extract package name and version find_package(ros_industrial_cmake_boilerplate REQUIRED) extract_package_metadata(pkg) -project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES CXX) +project(${pkg_extracted_name} VERSION ${pkg_extracted_version} LANGUAGES C CXX) if(WIN32) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)