summaryrefslogtreecommitdiff
path: root/Utilities/cmcurl/lib/CMakeLists.txt
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-11-06 15:31:38 -0500
committerBrad King <brad.king@kitware.com>2014-11-10 10:11:26 -0500
commitb18c9044122b0fbe7cc6c81efb48d0be8e065a23 (patch)
tree42c1e9bf749e86c1f51472aad551b732aedd583c /Utilities/cmcurl/lib/CMakeLists.txt
parent860f0a2ddc4b586d639caea1f9c7c10b381224e6 (diff)
downloadcmake-b18c9044122b0fbe7cc6c81efb48d0be8e065a23.tar.gz
curl: Drop inclusion of .rc file for static lib
The resource file is only needed for the curl .dll, so skip it when building the static library. This avoids the need to add the '/machine:' link flag on MS tools for creating a static library.
Diffstat (limited to 'Utilities/cmcurl/lib/CMakeLists.txt')
-rw-r--r--Utilities/cmcurl/lib/CMakeLists.txt6
1 files changed, 1 insertions, 5 deletions
diff --git a/Utilities/cmcurl/lib/CMakeLists.txt b/Utilities/cmcurl/lib/CMakeLists.txt
index b2bcf09046..3d5c3e3aa9 100644
--- a/Utilities/cmcurl/lib/CMakeLists.txt
+++ b/Utilities/cmcurl/lib/CMakeLists.txt
@@ -13,7 +13,7 @@ list(APPEND HHEADERS
${CURL_BINARY_DIR}/include/curl/curlbuild.h
)
-if(MSVC)
+if(MSVC AND NOT CURL_STATICLIB)
list(APPEND CSOURCES libcurl.rc)
endif()
@@ -94,10 +94,6 @@ add_library(
${HHEADERS} ${CSOURCES}
)
-if(MSVC AND CURL_STATICLIB)
- set_target_properties(${LIB_NAME} PROPERTIES STATIC_LIBRARY_FLAGS ${CMAKE_EXE_LINKER_FLAGS})
-endif()
-
target_link_libraries(${LIB_NAME} ${CURL_LIBS})
if(WIN32)