This is an automated email from the ASF dual-hosted git repository. cmcfarlen pushed a commit to branch 10.0.x in repository https://gitbox.apache.org/repos/asf/trafficserver.git
commit 9e94b24ca20377d2e3c5eaf0311ef2e178367444 Author: Brian Neradt <[email protected]> AuthorDate: Thu Mar 21 16:52:01 2024 -0500 Fix external libswoc builds (#11179) This fixes builds against external libswoc rather than the local ATS lib/swoc code. (cherry picked from commit a0c216f6771ab3f4cfc77127b09fe9eafca93acc) --- cmake/add_atsplugin.cmake | 6 ++++-- src/proxy/hdrs/CMakeLists.txt | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/cmake/add_atsplugin.cmake b/cmake/add_atsplugin.cmake index 80de5bb965..559cff1301 100644 --- a/cmake/add_atsplugin.cmake +++ b/cmake/add_atsplugin.cmake @@ -23,8 +23,10 @@ function(add_atsplugin name) target_link_libraries(${name} PRIVATE ts::tsapi ts::tsutil) else() target_include_directories( - ${name} PRIVATE "$<TARGET_PROPERTY:libswoc::libswoc,INCLUDE_DIRECTORIES>" - "$<TARGET_PROPERTY:yaml-cpp::yaml-cpp,INCLUDE_DIRECTORIES>" + ${name} + PRIVATE "$<TARGET_PROPERTY:libswoc::libswoc,INCLUDE_DIRECTORIES>" + "$<TARGET_PROPERTY:libswoc::libswoc,INTERFACE_INCLUDE_DIRECTORIES>" + "$<TARGET_PROPERTY:yaml-cpp::yaml-cpp,INCLUDE_DIRECTORIES>" ) endif() set_target_properties(${name} PROPERTIES PREFIX "") diff --git a/src/proxy/hdrs/CMakeLists.txt b/src/proxy/hdrs/CMakeLists.txt index dd8bad770c..d82587ec9c 100644 --- a/src/proxy/hdrs/CMakeLists.txt +++ b/src/proxy/hdrs/CMakeLists.txt @@ -51,10 +51,10 @@ if(BUILD_TESTING) unit_tests/test_URL.cc unit_tests/unit_test_main.cc ) - target_link_libraries(test_proxy_hdrs PRIVATE ts::hdrs ts::tscore ts::inkevent catch2::catch2) + target_link_libraries(test_proxy_hdrs PRIVATE ts::hdrs ts::tscore ts::inkevent libswoc::libswoc catch2::catch2) add_test(NAME test_proxy_hdrs COMMAND test_proxy_hdrs) add_executable(test_proxy_hdrs_xpack unit_tests/test_XPACK.cc) - target_link_libraries(test_proxy_hdrs_xpack PRIVATE ts::hdrs ts::tscore ts::tsutil libswoc catch2::catch2) + target_link_libraries(test_proxy_hdrs_xpack PRIVATE ts::hdrs ts::tscore ts::tsutil libswoc::libswoc catch2::catch2) add_test(NAME test_proxy_hdrs_xpack COMMAND test_proxy_hdrs_xpack) endif()
