From 5469800eef24a636fa0c4dae037df53188d81b25 Mon Sep 17 00:00:00 2001 From: FrancoisCarouge Date: Thu, 26 Oct 2023 23:33:38 -0700 Subject: [PATCH] [cmake] remove dead support and add missing print support --- linalg/eigen/CMakeLists.txt | 2 ++ sample/CMakeLists.txt | 2 -- support/CMakeLists.txt | 10 ++++++++++ test/CMakeLists.txt | 2 -- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/linalg/eigen/CMakeLists.txt b/linalg/eigen/CMakeLists.txt index e9be0fa87..21530ae38 100644 --- a/linalg/eigen/CMakeLists.txt +++ b/linalg/eigen/CMakeLists.txt @@ -36,6 +36,8 @@ OTHER DEALINGS IN THE SOFTWARE. For more information, please refer to ]] +include(FetchContent) + FetchContent_Declare( eigen GIT_REPOSITORY "https://gitlab.com/libeigen/eigen" diff --git a/sample/CMakeLists.txt b/sample/CMakeLists.txt index 395bd42c6..eb06d9f3e 100644 --- a/sample/CMakeLists.txt +++ b/sample/CMakeLists.txt @@ -36,8 +36,6 @@ OTHER DEALINGS IN THE SOFTWARE. For more information, please refer to ]] -include(FetchContent) - foreach(SAMPLE "kf_1x1x0_building_height.cpp" "kf_1x1x0_liquid_temperature.cpp" "kf_1x1x1_dog_position.cpp") get_filename_component(NAME ${SAMPLE} NAME_WE) diff --git a/support/CMakeLists.txt b/support/CMakeLists.txt index 79795a6ba..e185acfa6 100644 --- a/support/CMakeLists.txt +++ b/support/CMakeLists.txt @@ -106,6 +106,16 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") target_compile_options(kalman_options INTERFACE "/EHsc" "/W4") endif() +add_library(kalman_print INTERFACE) +target_sources(kalman_print INTERFACE FILE_SET "kalman_print_headers" TYPE + "HEADERS" FILES "print") + +install( + TARGETS kalman_print + EXPORT "kalman-target" + FILE_SET "kalman_print_headers" + DESTINATION "include/fcarouge") + include(CheckSourceCompiles) include(FetchContent) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index ea8d901aa..15164e0c4 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -36,8 +36,6 @@ OTHER DEALINGS IN THE SOFTWARE. For more information, please refer to ]] -include(FetchContent) - foreach( TEST "kalman_constructor_default_float_1x1x1.cpp"