windows Sun Apr 13 20:58:23 WEDT 2025
This commit is contained in:
parent
f53b7047f1
commit
d7ecdf0108
6 changed files with 605 additions and 38 deletions
|
@ -19,11 +19,16 @@ find_package(rmw REQUIRED)
|
|||
find_package(std_msgs REQUIRED)
|
||||
find_package(std_srvs REQUIRED)
|
||||
find_package(simple_timer REQUIRED)
|
||||
find_package(nlohmann_json REQUIRED)
|
||||
|
||||
# Library targets
|
||||
add_library(priority_executor
|
||||
src/priority_executor.cpp
|
||||
src/priority_memory_strategy.cpp
|
||||
src/performance_monitor.cpp
|
||||
src/default_executor.cpp
|
||||
src/usage_example.cpp
|
||||
src/multithread_priority_executor.cpp
|
||||
)
|
||||
target_include_directories(priority_executor PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
|
||||
|
@ -34,35 +39,7 @@ ament_target_dependencies(priority_executor
|
|||
rclcpp
|
||||
rcl
|
||||
simple_timer
|
||||
)
|
||||
|
||||
add_library(multithread_priority_executor
|
||||
src/multithread_priority_executor.cpp
|
||||
src/priority_memory_strategy.cpp
|
||||
)
|
||||
target_include_directories(multithread_priority_executor PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
|
||||
$<INSTALL_INTERFACE:include>
|
||||
)
|
||||
ament_target_dependencies(multithread_priority_executor
|
||||
rmw
|
||||
rclcpp
|
||||
rcl
|
||||
simple_timer
|
||||
)
|
||||
|
||||
add_library(default_executor
|
||||
src/default_executor.cpp
|
||||
)
|
||||
target_include_directories(default_executor PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
|
||||
$<INSTALL_INTERFACE:include>
|
||||
)
|
||||
ament_target_dependencies(default_executor
|
||||
rmw
|
||||
rclcpp
|
||||
rcl
|
||||
simple_timer
|
||||
nlohmann_json
|
||||
)
|
||||
|
||||
# Example executable
|
||||
|
@ -75,8 +52,6 @@ target_include_directories(usage_example PUBLIC
|
|||
)
|
||||
target_link_libraries(usage_example
|
||||
priority_executor
|
||||
multithread_priority_executor
|
||||
default_executor
|
||||
)
|
||||
ament_target_dependencies(usage_example
|
||||
rclcpp
|
||||
|
@ -98,7 +73,7 @@ install(
|
|||
)
|
||||
|
||||
install(
|
||||
TARGETS priority_executor multithread_priority_executor default_executor
|
||||
TARGETS priority_executor
|
||||
EXPORT export_${PROJECT_NAME}
|
||||
ARCHIVE DESTINATION lib
|
||||
LIBRARY DESTINATION lib
|
||||
|
@ -114,5 +89,5 @@ install(
|
|||
# Export and package configuration
|
||||
ament_export_include_directories(include)
|
||||
ament_export_targets(export_${PROJECT_NAME} HAS_LIBRARY_TARGET)
|
||||
ament_export_dependencies(rclcpp rcl rmw simple_timer)
|
||||
ament_export_dependencies(rclcpp rcl rmw simple_timer nlohmann_json)
|
||||
ament_package()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue