From a20180fbb771a20424312b34bdbc6e590858bfa9 Mon Sep 17 00:00:00 2001 From: Simon Quigley Date: Sun, 15 Dec 2024 01:13:08 -0600 Subject: [PATCH] Another whack-a-mole iteration --- cpp/CMakeLists.txt | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt index ed1008f..25287b3 100644 --- a/cpp/CMakeLists.txt +++ b/cpp/CMakeLists.txt @@ -21,8 +21,9 @@ include_directories(/srv/lubuntu-ci/repos/ci-tools/include/launchpadlib-cpp) # Create the shared library liblubuntuci.so add_library(lubuntuci SHARED common.cpp utilities.cpp) -target_include_directories(lubuntuci PUBLIC ${CMAKE_CURRENT_SOURCE_DIR} ${CURL_INCLUDE_DIRS}) -target_link_libraries(lubuntuci PRIVATE CURL::libcurl ${YAML_CPP_LIBRARIES} /srv/lubuntu-ci/repos/ci-tools/lib/liblaunchpad.so) +target_include_directories(lubuntuci PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}) +target_include_directories(lubuntuci PRIVATE ${CURL_INCLUDE_DIRS} ${YAML_CPP_LIBRARIES}) +target_link_libraries(lubuntuci PRIVATE CURL::libcurl yaml-cpp /srv/lubuntu-ci/repos/ci-tools/lib/liblaunchpad.so) # Ensure liblubuntuci has proper RPATH set_target_properties(lubuntuci PROPERTIES @@ -32,12 +33,13 @@ set_target_properties(lubuntuci PROPERTIES # build-packages executable add_executable(build-packages build-packages.cpp) -target_link_libraries(build-packages PRIVATE lubuntuci PkgConfig::LIBGIT2 ${LIBGIT2_LIBRARIES}) +target_include_directories(build-packages PRIVATE ${LIBGIT2_LIBRARIES}) +target_link_libraries(build-packages PRIVATE lubuntuci PkgConfig::LIBGIT2) # fetch-indexes executable add_executable(fetch-indexes fetch-indexes.cpp utilities.cpp) -target_include_directories(fetch-indexes PRIVATE ${CURL_INCLUDE_DIRS} ${ZLIB_INCLUDE_DIRS} /srv/lubuntu-ci/repos/ci-tools/include/launchpadlib-cpp) -target_link_libraries(fetch-indexes PRIVATE lubuntuci ZLIB::ZLIB) +target_include_directories(fetch-indexes PRIVATE ${CURL_INCLUDE_DIRS} ${YAML_CPP_LIBRARIES} ${ZLIB_INCLUDE_DIRS} /srv/lubuntu-ci/repos/ci-tools/include/launchpadlib-cpp) +target_link_libraries(fetch-indexes PRIVATE lubuntuci CURL::libcurl yaml-cpp ZLIB::ZLIB) # update-maintainer executable add_executable(update-maintainer update-maintainer.cpp)