forked from loafle/openapi-generator-original
[Client:C] [C-libcurl] cmake support specify path (#11790)
This commit is contained in:
@@ -34,12 +34,17 @@ set(PROJECT_VERSION_MAJOR 0)
|
||||
set(PROJECT_VERSION_MINOR 0)
|
||||
set(PROJECT_VERSION_PATCH 1)
|
||||
|
||||
find_package(CURL 7.58.0 REQUIRED)
|
||||
if(CURL_FOUND)
|
||||
if( (DEFINED CURL_INCLUDE_DIR) AND (DEFINED CURL_LIBRARIES))
|
||||
include_directories(${CURL_INCLUDE_DIR})
|
||||
set(PLATFORM_LIBRARIES ${PLATFORM_LIBRARIES} ${CURL_LIBRARIES} )
|
||||
else(CURL_FOUND)
|
||||
message(FATAL_ERROR "Could not find the CURL library and development files.")
|
||||
else()
|
||||
find_package(CURL 7.58.0 REQUIRED)
|
||||
if(CURL_FOUND)
|
||||
include_directories(${CURL_INCLUDE_DIR})
|
||||
set(PLATFORM_LIBRARIES ${PLATFORM_LIBRARIES} ${CURL_LIBRARIES} )
|
||||
else(CURL_FOUND)
|
||||
message(FATAL_ERROR "Could not find the CURL library and development files.")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(SRCS
|
||||
|
||||
Reference in New Issue
Block a user