diff --git a/ext/src/http/client/curl/CMakeLists.txt b/ext/src/http/client/curl/CMakeLists.txt index 4208de0607..2f63a686aa 100644 --- a/ext/src/http/client/curl/CMakeLists.txt +++ b/ext/src/http/client/curl/CMakeLists.txt @@ -5,7 +5,12 @@ if(CURL_FOUND) set_target_properties(http_client_curl PROPERTIES EXPORT_NAME http_client_curl) - target_link_libraries(http_client_curl PUBLIC CURL::libcurl) + if(TARGET CURL::libcurl) + target_link_libraries(http_client_curl PUBLIC CURL::libcurl) + else() + include_directories(${CURL_INCLUDE_DIRS}) + target_link_libraries(http_client_curl PUBLIC ${CURL_LIBRARIES}) + endif() install( TARGETS http_client_curl