From 2f0c4b3b3319d8e55d5325ce71b9530cc6a46516 Mon Sep 17 00:00:00 2001 From: Yutaka Kondo Date: Fri, 6 Dec 2024 14:25:23 +0900 Subject: [PATCH] use ament_cmake_auto Signed-off-by: Yutaka Kondo --- common/autoware_geography_utils/CMakeLists.txt | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/common/autoware_geography_utils/CMakeLists.txt b/common/autoware_geography_utils/CMakeLists.txt index b4ab5c2f74..72f68419a6 100644 --- a/common/autoware_geography_utils/CMakeLists.txt +++ b/common/autoware_geography_utils/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.14) project(autoware_geography_utils) -find_package(autoware_cmake REQUIRED) -autoware_package() +find_package(ament_cmake_auto REQUIRED) +ament_auto_find_build_dependencies() # GeographicLib find_package(PkgConfig) @@ -18,19 +18,19 @@ ament_auto_add_library(${PROJECT_NAME} SHARED src/lanelet2_projector.cpp ) -target_link_libraries(${PROJECT_NAME} +target_include_directories(${PROJECT_NAME} SYSTEM PUBLIC ${GeographicLib_INCLUDE_DIRS}) +ament_target_dependencies(${PROJECT_NAME} + autoware_lanelet2_extension + lanelet2_io ${GeographicLib_LIBRARIES} ) if(BUILD_TESTING) find_package(ament_cmake_ros REQUIRED) - file(GLOB_RECURSE test_files test/*.cpp) - ament_add_ros_isolated_gtest(test_${PROJECT_NAME} ${test_files}) - target_link_libraries(test_${PROJECT_NAME} - ${PROJECT_NAME} + ${PROJECT_NAME} ) endif()