From f8dcfa68b58587986a8007d3334be9f242f552a9 Mon Sep 17 00:00:00 2001 From: lyq Date: Tue, 30 Dec 2025 11:30:52 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E4=B8=89=E6=96=B9=E5=BA=93?= =?UTF-8?q?=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/remote_ctrl/CMakeLists.txt | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/remote_ctrl/CMakeLists.txt b/src/remote_ctrl/CMakeLists.txt index a56b672..f44afb0 100644 --- a/src/remote_ctrl/CMakeLists.txt +++ b/src/remote_ctrl/CMakeLists.txt @@ -11,11 +11,6 @@ find_package(rclcpp REQUIRED) find_package(sweeper_interfaces REQUIRED) find_package(ament_index_cpp REQUIRED) -# ======== include headers ======== -include_directories( - include -) - # ======== MQTT libs ======== if(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64") message(STATUS "[MQTT] using x86 static Paho") @@ -35,10 +30,20 @@ add_executable(remote_ctrl_node src/config.cpp ) +target_include_directories(remote_ctrl_node + PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/include +) + target_link_libraries(remote_ctrl_node ${PAHO_LIB} ) +target_include_directories(remote_ctrl_node + SYSTEM PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/include/paho_mqtt_3c +) + ament_target_dependencies(remote_ctrl_node rclcpp sweeper_interfaces