diff --git a/CMakeLists.txt b/CMakeLists.txt index 3b08971..ca2ff06 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,46 +17,8 @@ find_package(yaml-cpp REQUIRED) find_package(std_msgs REQUIRED) find_package(example_interfaces REQUIRED) -add_library( - moveit_middleware_benchmark_lib SHARED - src/scenarios/scenario_perception_pipeline.cpp - src/scenarios/scenario_basic_service_client.cpp) - -ament_target_dependencies( - moveit_middleware_benchmark_lib - PUBLIC - moveit_ros_planning_interface - rclcpp - benchmark - dynmsg - nav_msgs - std_msgs - yaml-cpp - example_interfaces) - -target_include_directories( - moveit_middleware_benchmark_lib - PUBLIC $ - $) - -target_link_libraries(moveit_middleware_benchmark_lib - PUBLIC benchmark::benchmark ${YAML_CPP_LIBRARIES}) - -add_executable(scenario_perception_pipeline_benchmark_main - src/scenario_perception_pipeline_benchmark_main.cpp) - -target_link_libraries(scenario_perception_pipeline_benchmark_main - PUBLIC moveit_middleware_benchmark_lib) - -add_executable(scenario_basic_service_client_benchmark_main - src/scenario_basic_service_client_benchmark_main.cpp) - -target_link_libraries(scenario_basic_service_client_benchmark_main - PUBLIC moveit_middleware_benchmark_lib) - -install(TARGETS scenario_perception_pipeline_benchmark_main - scenario_basic_service_client_benchmark_main - DESTINATION lib/moveit_middleware_benchmark) +add_subdirectory(src/scenario_basic_service_client) +add_subdirectory(src/scenario_perception_pipeline) install(DIRECTORY launch config DESTINATION share/moveit_middleware_benchmark) diff --git a/include/moveit_middleware_benchmark/scenarios/scenario_basic_service_client.hpp b/include/moveit_middleware_benchmark/scenario_basic_service_client/scenario_basic_service_client.hpp similarity index 100% rename from include/moveit_middleware_benchmark/scenarios/scenario_basic_service_client.hpp rename to include/moveit_middleware_benchmark/scenario_basic_service_client/scenario_basic_service_client.hpp diff --git a/include/moveit_middleware_benchmark/scenarios/scenario_perception_pipeline.hpp b/include/moveit_middleware_benchmark/scenario_perception_pipeline/scenario_perception_pipeline.hpp similarity index 100% rename from include/moveit_middleware_benchmark/scenarios/scenario_perception_pipeline.hpp rename to include/moveit_middleware_benchmark/scenario_perception_pipeline/scenario_perception_pipeline.hpp diff --git a/src/scenario_basic_service_client/CMakeLists.txt b/src/scenario_basic_service_client/CMakeLists.txt new file mode 100644 index 0000000..e3f084c --- /dev/null +++ b/src/scenario_basic_service_client/CMakeLists.txt @@ -0,0 +1,24 @@ +add_executable( + scenario_basic_service_client_benchmark_main + scenario_basic_service_client_benchmark_main.cpp + scenario_basic_service_client.cpp) + +ament_target_dependencies( + scenario_basic_service_client_benchmark_main + PUBLIC + rclcpp + benchmark + std_msgs + example_interfaces + ament_index_cpp) + +target_include_directories( + scenario_basic_service_client_benchmark_main + PUBLIC $ + $) + +target_link_libraries(scenario_basic_service_client_benchmark_main + PUBLIC benchmark::benchmark ${YAML_CPP_LIBRARIES}) + +install(TARGETS scenario_basic_service_client_benchmark_main + DESTINATION lib/moveit_middleware_benchmark) diff --git a/src/scenarios/scenario_basic_service_client.cpp b/src/scenario_basic_service_client/scenario_basic_service_client.cpp similarity index 97% rename from src/scenarios/scenario_basic_service_client.cpp rename to src/scenario_basic_service_client/scenario_basic_service_client.cpp index 5141b0c..f43587e 100644 --- a/src/scenarios/scenario_basic_service_client.cpp +++ b/src/scenario_basic_service_client/scenario_basic_service_client.cpp @@ -37,7 +37,7 @@ against basic service client works */ -#include "moveit_middleware_benchmark/scenarios/scenario_basic_service_client.hpp" +#include "moveit_middleware_benchmark/scenario_basic_service_client/scenario_basic_service_client.hpp" namespace moveit { diff --git a/src/scenario_basic_service_client_benchmark_main.cpp b/src/scenario_basic_service_client/scenario_basic_service_client_benchmark_main.cpp similarity index 95% rename from src/scenario_basic_service_client_benchmark_main.cpp rename to src/scenario_basic_service_client/scenario_basic_service_client_benchmark_main.cpp index 6653d55..2e53526 100644 --- a/src/scenario_basic_service_client_benchmark_main.cpp +++ b/src/scenario_basic_service_client/scenario_basic_service_client_benchmark_main.cpp @@ -37,7 +37,7 @@ against basic service client works */ -#include "moveit_middleware_benchmark/scenarios/scenario_basic_service_client.hpp" +#include "moveit_middleware_benchmark/scenario_basic_service_client/scenario_basic_service_client.hpp" int main(int argc, char** argv) { diff --git a/src/scenario_perception_pipeline/CMakeLists.txt b/src/scenario_perception_pipeline/CMakeLists.txt new file mode 100644 index 0000000..5069b9b --- /dev/null +++ b/src/scenario_perception_pipeline/CMakeLists.txt @@ -0,0 +1,26 @@ +add_executable( + scenario_perception_pipeline_benchmark_main + scenario_perception_pipeline_benchmark_main.cpp + scenario_perception_pipeline.cpp) + +ament_target_dependencies( + scenario_perception_pipeline_benchmark_main + PUBLIC + moveit_ros_planning_interface + rclcpp + benchmark + dynmsg + nav_msgs + yaml-cpp + example_interfaces) + +target_include_directories( + scenario_perception_pipeline_benchmark_main + PUBLIC $ + $) + +target_link_libraries(scenario_perception_pipeline_benchmark_main + PUBLIC benchmark::benchmark ${YAML_CPP_LIBRARIES}) + +install(TARGETS scenario_perception_pipeline_benchmark_main + DESTINATION lib/moveit_middleware_benchmark) diff --git a/src/scenarios/scenario_perception_pipeline.cpp b/src/scenario_perception_pipeline/scenario_perception_pipeline.cpp similarity index 98% rename from src/scenarios/scenario_perception_pipeline.cpp rename to src/scenario_perception_pipeline/scenario_perception_pipeline.cpp index d4ca7da..2d51503 100644 --- a/src/scenarios/scenario_perception_pipeline.cpp +++ b/src/scenario_perception_pipeline/scenario_perception_pipeline.cpp @@ -37,7 +37,7 @@ against perception pipeline */ -#include "moveit_middleware_benchmark/scenarios/scenario_perception_pipeline.hpp" +#include "moveit_middleware_benchmark/scenario_perception_pipeline/scenario_perception_pipeline.hpp" namespace moveit { diff --git a/src/scenario_perception_pipeline_benchmark_main.cpp b/src/scenario_perception_pipeline/scenario_perception_pipeline_benchmark_main.cpp similarity index 95% rename from src/scenario_perception_pipeline_benchmark_main.cpp rename to src/scenario_perception_pipeline/scenario_perception_pipeline_benchmark_main.cpp index 1327ef6..cf85f95 100644 --- a/src/scenario_perception_pipeline_benchmark_main.cpp +++ b/src/scenario_perception_pipeline/scenario_perception_pipeline_benchmark_main.cpp @@ -37,7 +37,7 @@ against perception pipeline */ -#include "moveit_middleware_benchmark/scenarios/scenario_perception_pipeline.hpp" +#include "moveit_middleware_benchmark/scenario_perception_pipeline/scenario_perception_pipeline.hpp" int main(int argc, char** argv) {