From 197645a0f7be6d24ae972fdbe1aa010e6591731e Mon Sep 17 00:00:00 2001 From: icedream2linxi Date: Sun, 26 Aug 2018 10:05:56 +0800 Subject: [icu] Support for compiling static libraries. --- ports/icu/portfile.cmake | 6 +++++- ports/icu/remove-MD-from-configure.patch | 18 ++++++++++++++++++ 2 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 ports/icu/remove-MD-from-configure.patch diff --git a/ports/icu/portfile.cmake b/ports/icu/portfile.cmake index ee558d886..f331537f9 100644 --- a/ports/icu/portfile.cmake +++ b/ports/icu/portfile.cmake @@ -28,7 +28,9 @@ vcpkg_download_distfile( vcpkg_extract_source_archive(${ARCHIVE} ${CURRENT_BUILDTREES_DIR}/src/icu-${VERSION}) vcpkg_apply_patches(SOURCE_PATH ${SOURCE_PATH} - PATCHES ${CMAKE_CURRENT_LIST_DIR}/disable-escapestr-tool.patch) + PATCHES ${CMAKE_CURRENT_LIST_DIR}/disable-escapestr-tool.patch + ${CMAKE_CURRENT_LIST_DIR}/remove-MD-from-configure.patch +) set(CONFIGURE_OPTIONS "--disable-samples --disable-tests") @@ -44,6 +46,8 @@ set(CONFIGURE_OPTIONS_DEBUG "--enable-debug --disable-release --prefix=${CURREN if(VCPKG_CMAKE_SYSTEM_NAME AND NOT VCPKG_CMAKE_SYSTEM_NAME STREQUAL "WindowsStore") set(BASH bash) + set(VCPKG_C_FLAGS "${VCPKG_C_FLAGS} -fPIC") + set(VCPKG_CXX_FLAGS "${VCPKG_CXX_FLAGS} -fPIC") # Configure release message(STATUS "Configuring ${TARGET_TRIPLET}-rel") diff --git a/ports/icu/remove-MD-from-configure.patch b/ports/icu/remove-MD-from-configure.patch new file mode 100644 index 000000000..d35205ebf --- /dev/null +++ b/ports/icu/remove-MD-from-configure.patch @@ -0,0 +1,18 @@ +diff -urN a/source/runConfigureICU b/source/runConfigureICU +--- a/source/runConfigureICU 2018-03-26 21:38:44.000000000 +0800 ++++ b/source/runConfigureICU 2018-08-26 09:04:53.197454400 +0800 +@@ -322,10 +322,10 @@ + THE_COMP="Microsoft Visual C++" + CC=cl; export CC + CXX=cl; export CXX +- RELEASE_CFLAGS='-Gy -MD' +- RELEASE_CXXFLAGS='-Gy -MD' +- DEBUG_CFLAGS='-Zi -MDd' +- DEBUG_CXXFLAGS='-Zi -MDd' ++ RELEASE_CFLAGS='-Gy' ++ RELEASE_CXXFLAGS='-Gy' ++ DEBUG_CFLAGS='-Zi' ++ DEBUG_CXXFLAGS='-Zi' + DEBUG_LDFLAGS='-DEBUG' + ;; + *BSD) -- cgit v1.2.3 From 711034e5834a1ffb937d09640c51bf29497752bd Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Tue, 28 Aug 2018 14:04:04 -0700 Subject: [icu] Bump package version --- ports/icu/CONTROL | 2 +- ports/icu/portfile.cmake | 12 +----------- 2 files changed, 2 insertions(+), 12 deletions(-) diff --git a/ports/icu/CONTROL b/ports/icu/CONTROL index 1fc3d39cc..602e4341a 100644 --- a/ports/icu/CONTROL +++ b/ports/icu/CONTROL @@ -1,3 +1,3 @@ Source: icu -Version: 61.1-2 +Version: 61.1-3 Description: Mature and widely used Unicode and localization library. diff --git a/ports/icu/portfile.cmake b/ports/icu/portfile.cmake index f331537f9..9e3d9c48b 100644 --- a/ports/icu/portfile.cmake +++ b/ports/icu/portfile.cmake @@ -1,19 +1,9 @@ -# 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 = -# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm) -# if (VCPKG_CMAKE_SYSTEM_NAME STREQUAL WindowsStore) message(FATAL_ERROR "Error: UWP builds are currently not supported.") endif() include(vcpkg_common_functions) + set(VERSION 61.1) set(VERSION2 61_1) set(ICU_VERSION_MAJOR 61) -- cgit v1.2.3