From b8936a7ce8ca06aafeb028faa3bc7d2f06b5e450 Mon Sep 17 00:00:00 2001 From: Marcus Holland-Moritz Date: Wed, 15 May 2024 17:33:46 +0200 Subject: [PATCH] build: more CMake cleanups --- CMakeLists.txt | 9 ++------- cmake/thrift_library.cmake | 2 -- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 1d5c4dd7..780d171b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -504,7 +504,7 @@ add_library(folly_light set_property(TARGET folly_light PROPERTY CXX_STANDARD 20) target_include_directories( - folly_light SYSTEM PRIVATE + folly_light SYSTEM PUBLIC ${CMAKE_CURRENT_BINARY_DIR}/folly ${CMAKE_CURRENT_SOURCE_DIR}/folly ) @@ -552,11 +552,6 @@ endif() add_library(follybenchmark_lite ${FOLLY_BENCHMARK_LITE_SRC}) set_property(TARGET follybenchmark_lite PROPERTY CXX_STANDARD 20) -target_include_directories( - follybenchmark_lite SYSTEM PRIVATE - ${CMAKE_CURRENT_BINARY_DIR}/folly - ${CMAKE_CURRENT_SOURCE_DIR}/folly -) apply_folly_compile_options_to_target(follybenchmark_lite) target_link_libraries(follybenchmark_lite folly_light) @@ -1021,7 +1016,7 @@ add_library( set_property(TARGET thrift_light PROPERTY CXX_STANDARD 20) target_link_libraries(thrift_light folly_light) -target_include_directories(thrift_light SYSTEM PRIVATE +target_include_directories(thrift_light SYSTEM PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift ${THRIFT_GENERATED_DIR} ) diff --git a/cmake/thrift_library.cmake b/cmake/thrift_library.cmake index e22e180d..30953c96 100644 --- a/cmake/thrift_library.cmake +++ b/cmake/thrift_library.cmake @@ -135,9 +135,7 @@ function(add_cpp2_thrift_library idlfile) add_library(${_THRIFT_TARGET} ${_THRIFT_LIB_SRC}) target_include_directories(${_THRIFT_TARGET} PUBLIC ${CMAKE_CURRENT_BINARY_DIR}/thrift - ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift ${_THRIFT_GENERATED_DIR}/thrift - ${_THRIFT_GENERATED_DIR} ) target_link_libraries(${_THRIFT_TARGET} PUBLIC thrift_light) if(NOT WIN32)