From 8d90dededa4ff93ce7df76980c35e2e06225cfde Mon Sep 17 00:00:00 2001 From: Simon Quigley Date: Sun, 15 Dec 2024 01:18:43 -0600 Subject: [PATCH] This should hopefully get it to link now --- cpp/CMakeLists.txt | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt index 25287b3..49aa3a5 100644 --- a/cpp/CMakeLists.txt +++ b/cpp/CMakeLists.txt @@ -22,8 +22,7 @@ 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}) -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) +target_link_libraries(lubuntuci PUBLIC yaml-cpp::yaml-cpp PRIVATE CURL::libcurl /srv/lubuntu-ci/repos/ci-tools/lib/liblaunchpad.so) # Ensure liblubuntuci has proper RPATH set_target_properties(lubuntuci PROPERTIES @@ -33,16 +32,18 @@ set_target_properties(lubuntuci PROPERTIES # build-packages executable add_executable(build-packages build-packages.cpp) -target_include_directories(build-packages PRIVATE ${LIBGIT2_LIBRARIES}) -target_link_libraries(build-packages PRIVATE lubuntuci PkgConfig::LIBGIT2) +target_include_directories(build-packages PRIVATE /srv/lubuntu-ci/repos/ci-tools/include/launchpadlib-cpp) +target_link_libraries(build-packages PRIVATE lubuntuci PkgConfig::LIBGIT2 yaml-cpp::yaml-cpp) # fetch-indexes executable add_executable(fetch-indexes fetch-indexes.cpp utilities.cpp) -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) +target_include_directories(fetch-indexes PRIVATE /srv/lubuntu-ci/repos/ci-tools/include/launchpadlib-cpp) +target_link_libraries(fetch-indexes PRIVATE lubuntuci CURL::libcurl yaml-cpp::yaml-cpp ZLIB::ZLIB) # update-maintainer executable add_executable(update-maintainer update-maintainer.cpp) +target_include_directories(update-maintainer PRIVATE /srv/lubuntu-ci/repos/ci-tools/include/launchpadlib-cpp) +target_link_libraries(update-maintainer PRIVATE lubuntuci yaml-cpp::yaml-cpp CURL::libcurl) # Ensure executables have proper RPATH set_target_properties(build-packages fetch-indexes update-maintainer PROPERTIES