From 69600a0dfee552aab711d41fc52498eb2fcef9b3 Mon Sep 17 00:00:00 2001 From: autoantwort <41973254+autoantwort@users.noreply.github.com> Date: Thu, 9 Nov 2023 20:27:39 +0100 Subject: [PATCH] [zlib-ng] add flags in pkgconfig (#34903) --- ports/zlib-ng/fix-cflags.patch | 24 ++++++++++++++++++++++++ ports/zlib-ng/portfile.cmake | 2 ++ ports/zlib-ng/vcpkg.json | 1 + versions/baseline.json | 2 +- versions/z-/zlib-ng.json | 5 +++++ 5 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 ports/zlib-ng/fix-cflags.patch diff --git a/ports/zlib-ng/fix-cflags.patch b/ports/zlib-ng/fix-cflags.patch new file mode 100644 index 00000000000000..6d2a3511201560 --- /dev/null +++ b/ports/zlib-ng/fix-cflags.patch @@ -0,0 +1,24 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index a645ad6e..fbc2bdba 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1159,6 +1159,9 @@ else() + endif() + + set(ZLIB_PC ${CMAKE_CURRENT_BINARY_DIR}/zlib${SUFFIX}.pc) ++if(WITH_GZFILEOP) ++ set(PKG_CONFIG_CFLAGS "-DWITH_GZFILEOP") ++endif() + configure_file(${CMAKE_CURRENT_SOURCE_DIR}/zlib.pc.cmakein + ${ZLIB_PC} @ONLY) + configure_file(${CMAKE_CURRENT_BINARY_DIR}/zconf${SUFFIX}.h.cmakein +diff --git a/zlib.pc.cmakein b/zlib.pc.cmakein +index 3d440ce6..df8bf9f0 100644 +--- a/zlib.pc.cmakein ++++ b/zlib.pc.cmakein +@@ -11,4 +11,4 @@ Version: @ZLIB_FULL_VERSION@ + + Requires: + Libs: -L${libdir} -L${sharedlibdir} -lz@SUFFIX@ +-Cflags: -I${includedir} ++Cflags: -I${includedir} @PKG_CONFIG_CFLAGS@ diff --git a/ports/zlib-ng/portfile.cmake b/ports/zlib-ng/portfile.cmake index e4a26f40f3a075..646b8abe8bcc1a 100644 --- a/ports/zlib-ng/portfile.cmake +++ b/ports/zlib-ng/portfile.cmake @@ -4,6 +4,8 @@ vcpkg_from_github( REF "${VERSION}" SHA512 cb987c0b20a11fca5361dce94e53dead7364e739a984545c38ad4bf0c7fedd83d5d62530d979eca2182da88d7507a9bec8d3f5abff41e92ab5a63ac61001502e HEAD_REF develop + PATCHES + fix-cflags.patch ) vcpkg_cmake_configure( diff --git a/ports/zlib-ng/vcpkg.json b/ports/zlib-ng/vcpkg.json index d3093f486f8976..d566b33e81448d 100644 --- a/ports/zlib-ng/vcpkg.json +++ b/ports/zlib-ng/vcpkg.json @@ -1,6 +1,7 @@ { "name": "zlib-ng", "version": "2.1.3", + "port-version": 1, "description": "zlib replacement with optimizations for 'next generation' systems", "homepage": "https://github.com/zlib-ng/zlib-ng", "license": "Zlib", diff --git a/versions/baseline.json b/versions/baseline.json index 87a725d7f5357c..b78b166a3c554f 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -9302,7 +9302,7 @@ }, "zlib-ng": { "baseline": "2.1.3", - "port-version": 0 + "port-version": 1 }, "zlmediakit": { "baseline": "2023-08-12", diff --git a/versions/z-/zlib-ng.json b/versions/z-/zlib-ng.json index 4155c7899e24aa..5ae306f6008b5e 100644 --- a/versions/z-/zlib-ng.json +++ b/versions/z-/zlib-ng.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "48a2a573758db5e1b96e889043fffaf453fa9cf4", + "version": "2.1.3", + "port-version": 1 + }, { "git-tree": "b5618019c0972a9e8bb9422609352679cf248f85", "version": "2.1.3",