aboutsummaryrefslogtreecommitdiff
path: root/ports
diff options
context:
space:
mode:
authorLong Nguyen <nguyen.long.908132@gmail.com>2020-08-22 07:45:42 +0700
committerGitHub <noreply@github.com>2020-08-21 17:45:42 -0700
commitd355b3fae03d6626437738151724610b593dc81c (patch)
tree98206aa8d4a581e4accbec0bcad07dbaad705d4a /ports
parentd80a3de3091c7a882e9335888e03b3695b607054 (diff)
downloadvcpkg-d355b3fae03d6626437738151724610b593dc81c.tar.gz
vcpkg-d355b3fae03d6626437738151724610b593dc81c.zip
[many ports] Fix various problems with mingw (#12886)
Diffstat (limited to 'ports')
-rw-r--r--ports/freetype/CONTROL2
-rw-r--r--ports/freetype/portfile.cmake2
-rw-r--r--ports/libmodplug/CONTROL3
-rw-r--r--ports/libmodplug/portfile.cmake11
-rw-r--r--ports/opus/portfile.cmake9
5 files changed, 21 insertions, 6 deletions
diff --git a/ports/freetype/CONTROL b/ports/freetype/CONTROL
index dcec495d7..072382ebc 100644
--- a/ports/freetype/CONTROL
+++ b/ports/freetype/CONTROL
@@ -1,6 +1,6 @@
Source: freetype
Version: 2.10.2
-Port-Version: 2
+Port-Version: 3
Build-Depends: zlib, brotli
Homepage: https://www.freetype.org/
Description: A library to render fonts.
diff --git a/ports/freetype/portfile.cmake b/ports/freetype/portfile.cmake
index f62f34728..b0152b31c 100644
--- a/ports/freetype/portfile.cmake
+++ b/ports/freetype/portfile.cmake
@@ -66,7 +66,7 @@ if(EXISTS "${CURRENT_PACKAGES_DIR}/lib/pkgconfig/freetype2.pc")
string(REPLACE "-I\${includedir}/freetype2" "-I\${includedir}" _contents "${_contents}")
file(WRITE "${CURRENT_PACKAGES_DIR}/lib/pkgconfig/freetype2.pc" "${_contents}")
endif()
-vcpkg_fixup_pkgconfig()
+vcpkg_fixup_pkgconfig(SYSTEM_LIBRARIES m)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
diff --git a/ports/libmodplug/CONTROL b/ports/libmodplug/CONTROL
index 7fd84e775..c8339b104 100644
--- a/ports/libmodplug/CONTROL
+++ b/ports/libmodplug/CONTROL
@@ -1,4 +1,5 @@
Source: libmodplug
-Version: 0.8.9.0-5
+Version: 0.8.9.0
+Port-Version: 6
Homepage: https://github.com/Konstanty/libmodplug
Description: The ModPlug mod file playing library.
diff --git a/ports/libmodplug/portfile.cmake b/ports/libmodplug/portfile.cmake
index 74dcfa264..9cc8e5ac3 100644
--- a/ports/libmodplug/portfile.cmake
+++ b/ports/libmodplug/portfile.cmake
@@ -31,11 +31,16 @@ vcpkg_install_cmake()
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
-if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
+if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic AND VCPKG_TARGET_IS_WINDOWS)
+ if(VCPKG_TARGET_IS_MINGW)
+ set(BIN_NAME libmodplug.dll)
+ else()
+ set(BIN_NAME modplug.dll)
+ endif()
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/bin)
- file(RENAME ${CURRENT_PACKAGES_DIR}/lib/modplug.dll ${CURRENT_PACKAGES_DIR}/bin/modplug.dll)
+ file(RENAME ${CURRENT_PACKAGES_DIR}/lib/${BIN_NAME} ${CURRENT_PACKAGES_DIR}/bin/${BIN_NAME})
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/debug/bin)
- file(RENAME ${CURRENT_PACKAGES_DIR}/debug/lib/modplug.dll ${CURRENT_PACKAGES_DIR}/debug/bin/modplug.dll)
+ file(RENAME ${CURRENT_PACKAGES_DIR}/debug/lib/${BIN_NAME} ${CURRENT_PACKAGES_DIR}/debug/bin/${BIN_NAME})
vcpkg_copy_pdbs()
endif()
diff --git a/ports/opus/portfile.cmake b/ports/opus/portfile.cmake
index eb7b90cea..4102542c1 100644
--- a/ports/opus/portfile.cmake
+++ b/ports/opus/portfile.cmake
@@ -14,9 +14,18 @@ vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
avx AVX_SUPPORTED
)
+if(VCPKG_TARGET_IS_MINGW)
+ set(STACK_PROTECTOR OFF)
+ string(APPEND VCPKG_C_FLAGS "-D_FORTIFY_SOURCE=0")
+ string(APPEND VCPKG_CXX_FLAGS "-D_FORTIFY_SOURCE=0")
+else()
+ set(STACK_PROTECTOR ON)
+endif()
+
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
OPTIONS ${FEATURE_OPTIONS}
+ -DOPUS_STACK_PROTECTOR=${STACK_PROTECTOR}
PREFER_NINJA)
vcpkg_install_cmake()
vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/Opus)