aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcDc <cdc.seacave@gmail.com>2017-11-17 13:48:52 +0200
committercDc <cdc.seacave@gmail.com>2017-11-17 13:48:52 +0200
commit85fe5932cf171359f997869a5cb351df7031e51d (patch)
tree609d3b043a609dcda0f8233d81ec4343b5c4d91c
parentb2e1dc3e5a4224bd06f1aaa52c87f5c8939787ae (diff)
downloadvcpkg-85fe5932cf171359f997869a5cb351df7031e51d.tar.gz
vcpkg-85fe5932cf171359f997869a5cb351df7031e51d.zip
[ceres] enable static CRT linkage for MSVC
-rw-r--r--ports/ceres/portfile.cmake7
1 files changed, 6 insertions, 1 deletions
diff --git a/ports/ceres/portfile.cmake b/ports/ceres/portfile.cmake
index 49353205e..e8ae03ce4 100644
--- a/ports/ceres/portfile.cmake
+++ b/ports/ceres/portfile.cmake
@@ -1,5 +1,9 @@
+set(MSVC_USE_STATIC_CRT_VALUE OFF)
if(VCPKG_CRT_LINKAGE STREQUAL "static")
- message(FATAL_ERROR "Ceres does not currently support static CRT linkage")
+ if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
+ message(FATAL_ERROR "Ceres does not currently support mixing static CRT and dynamic library linkage")
+ endif()
+ set(MSVC_USE_STATIC_CRT_VALUE ON)
endif()
include(vcpkg_common_functions)
@@ -32,6 +36,7 @@ vcpkg_configure_cmake(
-DSUITESPARSE=ON
-DGFLAGS_PREFER_EXPORTED_GFLAGS_CMAKE_CONFIGURATION=OFF # TheiaSfm doesn't work well with this
-DGLOG_PREFER_EXPORTED_GLOG_CMAKE_CONFIGURATION=OFF # TheiaSfm doesn't work well with this
+ -DMSVC_USE_STATIC_CRT=${MSVC_USE_STATIC_CRT_VALUE}
)
vcpkg_install_cmake()