From d1d5f47250dab68ce192496e190ba43d59b05ace Mon Sep 17 00:00:00 2001 From: Lewie Donckers Date: Wed, 9 Feb 2022 13:59:52 +0000 Subject: [PATCH 1/2] Stricter compiler settings. --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e146a50e..aa3a08e3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,4 @@ cmake_minimum_required(VERSION 3.0.2) -add_compile_options(-std=c++17) project(path_tracking_pid) ## Find catkin and any catkin packages @@ -67,6 +66,7 @@ add_library(${PROJECT_NAME} src/visualization.cpp ) add_dependencies(${PROJECT_NAME} ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS} ${PROJECT_NAME}_gencfg) +target_compile_options(${PROJECT_NAME} PUBLIC -std=c++17 -Wall -Wextra -Wno-unused-parameter -Werror) target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES}) include_directories( From f603fecff527321a9ee0165845981bd4fc578ad6 Mon Sep 17 00:00:00 2001 From: Lewie Donckers Date: Tue, 15 Feb 2022 13:07:02 +0000 Subject: [PATCH 2/2] Reworked to add_compile_options(). --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index aa3a08e3..4fe52cd3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,5 @@ cmake_minimum_required(VERSION 3.0.2) +add_compile_options(-std=c++17 -Wall -Wextra -Wno-unused-parameter -Werror) project(path_tracking_pid) ## Find catkin and any catkin packages @@ -66,7 +67,6 @@ add_library(${PROJECT_NAME} src/visualization.cpp ) add_dependencies(${PROJECT_NAME} ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS} ${PROJECT_NAME}_gencfg) -target_compile_options(${PROJECT_NAME} PUBLIC -std=c++17 -Wall -Wextra -Wno-unused-parameter -Werror) target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES}) include_directories(