Skip to content

Commit

Permalink
fix cxx target version
Browse files Browse the repository at this point in the history
  • Loading branch information
Levi-Armstrong committed Jul 25, 2024
1 parent cae74c0 commit 0312bf6
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion dependencies.repos
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ repositories:
ros_industrial_cmake_boilerplate:
type: git
url: https://github.com/ros-industrial/ros_industrial_cmake_boilerplate.git
version: 0.5.4
version: 0.6.2
4 changes: 2 additions & 2 deletions rct_common/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5.0)
cmake_minimum_required(VERSION 3.16.0)

# Extract package name and version from package.xml
find_package(ros_industrial_cmake_boilerplate REQUIRED)
Expand All @@ -19,7 +19,7 @@ endif()
find_gtest()

add_library(${PROJECT_NAME} INTERFACE)
target_compile_options(${PROJECT_NAME} INTERFACE -std=c++11)
target_compile_features(${PROJECT_NAME} INTERFACE cxx_std_11)
target_include_directories(${PROJECT_NAME} INTERFACE "$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
"$<INSTALL_INTERFACE:include>")
target_link_libraries(${PROJECT_NAME} INTERFACE Eigen3::Eigen)
Expand Down
2 changes: 1 addition & 1 deletion rct_examples/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5.0)
cmake_minimum_required(VERSION 3.16.0)

# Extract package name and version from package.xml
find_package(ros_industrial_cmake_boilerplate REQUIRED)
Expand Down
6 changes: 3 additions & 3 deletions rct_image_tools/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5.0)
cmake_minimum_required(VERSION 3.16.0)

# Extract package name and version from package.xml
find_package(ros_industrial_cmake_boilerplate REQUIRED)
Expand Down Expand Up @@ -30,7 +30,7 @@ add_library(
src/${PROJECT_NAME}/aruco_finder.cpp
src/${PROJECT_NAME}/charuco_grid_target.cpp
src/${PROJECT_NAME}/charuco_finder.cpp)
target_compile_options(${PROJECT_NAME} PUBLIC -std=c++11)
target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_11)
target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wextra)
target_include_directories(${PROJECT_NAME} PUBLIC "$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
"$<INSTALL_INTERFACE:include>")
Expand All @@ -49,7 +49,7 @@ target_link_libraries(

# Modified circle grid finder executable TODO: turn this into a unit test
add_executable(${PROJECT_NAME}_test src/target_finder_tests.cpp)
target_compile_options(${PROJECT_NAME}_test PUBLIC -std=c++11)
target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11)
target_compile_options(${PROJECT_NAME}_test PRIVATE -Wall -Wextra)
target_include_directories(${PROJECT_NAME}_test PUBLIC "$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
"$<INSTALL_INTERFACE:include>")
Expand Down
4 changes: 2 additions & 2 deletions rct_optimizations/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.5.0)
cmake_minimum_required(VERSION 3.16.0)

# Extract package name and version from package.xml
find_package(ros_industrial_cmake_boilerplate REQUIRED)
Expand Down Expand Up @@ -40,7 +40,7 @@ add_library(
# DH Chain Kinematic Calibration
src/${PROJECT_NAME}/dh_chain.cpp
src/${PROJECT_NAME}/dh_chain_kinematic_calibration.cpp)
target_compile_options(${PROJECT_NAME} PUBLIC -std=c++11)
target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_11)
target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wextra)
target_include_directories(${PROJECT_NAME} PUBLIC "$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>"
"$<INSTALL_INTERFACE:include>")
Expand Down
8 changes: 6 additions & 2 deletions rct_ros_tools/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.5.0)
cmake_minimum_required(VERSION 3.16.0)
project(rct_ros_tools)

add_compile_options(-std=c++11 -Wall -Wextra)
add_compile_options(-Wall -Wextra)

find_package(rct_common REQUIRED)
find_package(rct_optimizations REQUIRED)
Expand Down Expand Up @@ -71,13 +71,15 @@ target_link_libraries(
rct::rct_optimizations
rct::rct_image_tools
rct::rct_common)
target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_11)

add_library(${PROJECT_NAME}_target_loader_plugins src/target_loader_plugins.cpp)
target_link_libraries(
${PROJECT_NAME}_target_loader_plugins
${catkin_LIBRARIES}
yaml-cpp
rct::rct_image_tools)
target_compile_features(${PROJECT_NAME}_target_loader_plugins PUBLIC cxx_std_11)

# Executable for collecting data sets via subscribers and triggered with services See readme (TODO: Write a readme)
add_executable(${PROJECT_NAME}_cmd src/command_line_cal.cpp)
Expand All @@ -88,6 +90,7 @@ target_link_libraries(
${catkin_LIBRARIES}
${PROJECT_NAME}
rct::rct_image_tools)
target_compile_features(${PROJECT_NAME}_cmd PRIVATE cxx_std_11)

# ######################################################################################################################
# Testing ##
Expand All @@ -104,6 +107,7 @@ if(CATKIN_ENABLE_TESTING AND RCT_BUILD_TESTS)
GTest::GTest
GTest::Main
${catkin_LIBRARIES})
target_compile_features(${PROJECT_NAME}_target_finder_plugin_utest PRIVATE cxx_std_11)
endif()

# ######################################################################################################################
Expand Down
2 changes: 1 addition & 1 deletion robot_cal_tools/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 2.8.3)
cmake_minimum_required(VERSION 3.16.0)
project(robot_cal_tools)
find_package(catkin REQUIRED)
catkin_metapackage()

0 comments on commit 0312bf6

Please sign in to comment.