aboutsummaryrefslogtreecommitdiff
path: root/ports/gts
diff options
context:
space:
mode:
authorRobert Schumacher <roschuma@microsoft.com>2018-02-23 22:32:02 -0800
committerRobert Schumacher <roschuma@microsoft.com>2018-02-23 22:32:02 -0800
commit51f6cf724c7534397bf13cf58fb9842ffde9c7ca (patch)
tree09692cd5205dbe13db6f75ba4263f9e7ea0a7ad8 /ports/gts
parentfee4acc543e3801eed474495061875d0484e0bd3 (diff)
downloadvcpkg-51f6cf724c7534397bf13cf58fb9842ffde9c7ca.tar.gz
vcpkg-51f6cf724c7534397bf13cf58fb9842ffde9c7ca.zip
[exiv2] Fix static builds. [gts] Add early detection for CRT linkage.
Diffstat (limited to 'ports/gts')
-rw-r--r--ports/gts/portfile.cmake33
1 files changed, 14 insertions, 19 deletions
diff --git a/ports/gts/portfile.cmake b/ports/gts/portfile.cmake
index d55f5dc66..14a5e2bfa 100644
--- a/ports/gts/portfile.cmake
+++ b/ports/gts/portfile.cmake
@@ -1,29 +1,24 @@
-# Common Ambient Variables:
-# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT}
-# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET}
-# CURRENT_PORT_DIR = ${VCPKG_ROOT_DIR}\ports\${PORT}
-# PORT = current port name (zlib, etc)
-# TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc)
-# VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic)
-# VCPKG_LIBRARY_LINKAGE = target library linkage type (static, dynamic)
-# VCPKG_ROOT_DIR = <C:\path\to\current\vcpkg>
-# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm)
-#
+if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
+ message("gts does not support building statically -- building dynamically instead")
+ set(VCPKG_LIBRARY_LINKAGE "dynamic")
+endif()
+
+if(VCPKG_CRT_LINKAGE STREQUAL "static")
+ message("gts can only be built dynamically, and therefore cannot static link the CRT")
+endif()
include(vcpkg_common_functions)
-vcpkg_from_github(OUT_SOURCE_PATH SOURCE_PATH
- REPO "finetjul/gts"
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO finetjul/gts
REF c4da61ae075f355d9ecc9f2d4767acf777f54c2b
- HEAD_REF master
SHA512 e53d11213c26cbda08ae62e6388aee0a14d2884de72268ad25d10a23e77baa53a2b1151c5cc7643b059ded82b8edf0da79144c3108949fdc515168cac13ffca9
+ HEAD_REF master
)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
- PREFER_NINJA # Disable this option if project cannot be built with Ninja
- # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2
- # OPTIONS_RELEASE -DOPTIMIZE=1
- # OPTIONS_DEBUG -DDEBUGGABLE=1
+ PREFER_NINJA
)
vcpkg_install_cmake()
@@ -33,4 +28,4 @@ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
# Handle copyright
file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/gts RENAME copyright)
-vcpkg_copy_pdbs() \ No newline at end of file
+vcpkg_copy_pdbs()