From ab3a2b5e09d4b71d48b7e9cf51d93c64f50cfc53 Mon Sep 17 00:00:00 2001 From: Kai Pastor Date: Thu, 1 Jul 2021 16:22:56 +0200 Subject: [PATCH] [curl] Fix linker flags in curl-config and libcurl.pc for osx (#17790) * Fix exported framework linker flags for osx * x-add-version * Remove cmake version check * Update git-tree --- ports/curl/0020-fix-pc-file.patch | 16 ++++++++++++++++ ports/curl/portfile.cmake | 1 + ports/curl/vcpkg.json | 2 +- versions/baseline.json | 2 +- versions/c-/curl.json | 5 +++++ 5 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 ports/curl/0020-fix-pc-file.patch diff --git a/ports/curl/0020-fix-pc-file.patch b/ports/curl/0020-fix-pc-file.patch new file mode 100644 index 0000000000..cd79597821 --- /dev/null +++ b/ports/curl/0020-fix-pc-file.patch @@ -0,0 +1,16 @@ +diff -urw a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt 2021-05-10 20:46:52.204346972 +0200 ++++ b/CMakeLists.txt 2021-05-11 19:39:00.065235266 +0200 +@@ -1482,6 +1482,12 @@ + message(WARNING "Bad lib in library list: ${_libname}") + continue() + endif() ++ elseif(_lib MATCHES "^(.*)/([^/]*)[.]framework$") ++ if(CMAKE_MATCH_1 IN_LIST CMAKE_C_IMPLICIT_LINK_FRAMEWORK_DIRECTORIES) ++ set(_lib "-framework ${CMAKE_MATCH_2}") ++ else() ++ set(_lib "-framework ${_lib}") ++ endif() + endif() + if(_lib MATCHES ".*/.*" OR _lib MATCHES "^-") + set(LIBCURL_LIBS "${LIBCURL_LIBS} ${_lib}") diff --git a/ports/curl/portfile.cmake b/ports/curl/portfile.cmake index 3512adeaf8..6d410fb58b 100644 --- a/ports/curl/portfile.cmake +++ b/ports/curl/portfile.cmake @@ -13,6 +13,7 @@ vcpkg_from_github( 0010_fix_othertests_cmake.patch 0011_fix_static_build.patch 0012-fix-dependency-idn2.patch + 0020-fix-pc-file.patch ) string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" CURL_STATICLIB) diff --git a/ports/curl/vcpkg.json b/ports/curl/vcpkg.json index 6efa34f0f6..7059f6d474 100644 --- a/ports/curl/vcpkg.json +++ b/ports/curl/vcpkg.json @@ -1,7 +1,7 @@ { "name": "curl", "version": "7.74.0", - "port-version": 7, + "port-version": 8, "description": "A library for transferring data with URLs", "homepage": "https://github.com/curl/curl", "dependencies": [ diff --git a/versions/baseline.json b/versions/baseline.json index a6259aa2b8..a63cc64c31 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1562,7 +1562,7 @@ }, "curl": { "baseline": "7.74.0", - "port-version": 7 + "port-version": 8 }, "curlpp": { "baseline": "2018-06-15-3", diff --git a/versions/c-/curl.json b/versions/c-/curl.json index dfca5d4c4a..e0b511bb64 100644 --- a/versions/c-/curl.json +++ b/versions/c-/curl.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "cd05855cc1cd2d0f221664f0bfbe639b685fa028", + "version": "7.74.0", + "port-version": 8 + }, { "git-tree": "2184d79bb98ed36af015203385175cade013d8af", "version": "7.74.0",