diff --git a/.drone.yml b/.drone.yml index 0a03116..877187e 100644 --- a/.drone.yml +++ b/.drone.yml @@ -92,7 +92,7 @@ steps: - alias apt-get='rm -f /var/cache/apt/archives/lock && apt-get' - apt-get update -q - apt-get install -qq build-essential cmake clang pkg-config - - apt-get install -qq catch libcgicc-dev nlohmann-json-dev libgit2-dev libcurl4-openssl-dev + - apt-get install -qq catch libcgicc-dev nlohmann-json-dev libgit2-dev libcurl4-gnutls-dev - rm -rf build && mkdir -p build && cd build - cmake -G "Unix Makefiles" -DWITH_TESTS=YES .. - make VERBOSE=1 diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 7802477..29be4d8 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -18,8 +18,13 @@ target_link_libraries(fediblock PkgConfig::cgicc nlohmann_json std::filesystem - PkgConfig::libgit2 - CURL::libcurl) + PkgConfig::libgit2) + +if(${CMAKE_VERSION} VERSION_LESS 3.12) + target_link_libraries(fediblock PUBLIC ${CURL_LIBRARIES}) +else() + target_link_libraries(fediblock PUBLIC CURL::libcurl) +endif() add_executable(${PROJECT_NAME} main.cpp)