From c85581f9ccd951abbdafc7e36e0169e08703701e Mon Sep 17 00:00:00 2001 From: autoantwort <41973254+autoantwort@users.noreply.github.com> Date: Fri, 19 Nov 2021 05:42:56 +0100 Subject: [PATCH] [apr-util] no absolute paths (#21453) --- ports/apr-util/portfile.cmake | 21 ++++++++++++++------- ports/apr-util/vcpkg.json | 9 +++++++-- versions/a-/apr-util.json | 5 +++++ versions/baseline.json | 2 +- 4 files changed, 27 insertions(+), 10 deletions(-) diff --git a/ports/apr-util/portfile.cmake b/ports/apr-util/portfile.cmake index 1065bdb723..befefb4fca 100644 --- a/ports/apr-util/portfile.cmake +++ b/ports/apr-util/portfile.cmake @@ -8,7 +8,7 @@ vcpkg_download_distfile(ARCHIVE if(VCPKG_TARGET_IS_WINDOWS) vcpkg_extract_source_archive_ex( OUT_SOURCE_PATH SOURCE_PATH - ARCHIVE ${ARCHIVE} + ARCHIVE "${ARCHIVE}" PATCHES use-vcpkg-expat.patch apr.patch @@ -22,9 +22,8 @@ if(VCPKG_TARGET_IS_WINDOWS) set(APU_DECLARE_STATIC ON) endif() - vcpkg_configure_cmake( - SOURCE_PATH ${SOURCE_PATH} - PREFER_NINJA + vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}" OPTIONS -DAPU_DECLARE_EXPORT=${APU_DECLARE_EXPORT} -DAPU_DECLARE_STATIC=${APU_DECLARE_STATIC} @@ -32,7 +31,7 @@ if(VCPKG_TARGET_IS_WINDOWS) -DDISABLE_INSTALL_HEADERS=ON ) - vcpkg_install_cmake() + vcpkg_cmake_install() vcpkg_copy_pdbs() file(READ ${CURRENT_PACKAGES_DIR}/include/apu.h APU_H) @@ -43,7 +42,7 @@ if(VCPKG_TARGET_IS_WINDOWS) endif() file(WRITE ${CURRENT_PACKAGES_DIR}/include/apu.h "${APU_H}") -else(VCPKG_TARGET_IS_WINDOWS) +else() vcpkg_extract_source_archive_ex( OUT_SOURCE_PATH SOURCE_PATH ARCHIVE ${ARCHIVE} @@ -77,7 +76,15 @@ else(VCPKG_TARGET_IS_WINDOWS) vcpkg_install_make() + vcpkg_fixup_pkgconfig() + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/tools/apr-util/bin/apu-1-config" "${CURRENT_INSTALLED_DIR}" "`dirname $0`/../../..") + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/tools/apr-util/bin/apu-1-config" "${CURRENT_BUILDTREES_DIR}" "not/existing") + if(NOT VCPKG_BUILD_TYPE) + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/tools/apr-util/debug/bin/apu-1-config" "${CURRENT_INSTALLED_DIR}" "`dirname $0`/../../../..") + vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/tools/apr-util/debug/bin/apu-1-config" "${CURRENT_BUILDTREES_DIR}" "not/existing") + endif() + endif() # Handle copyright -file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright) +file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) diff --git a/ports/apr-util/vcpkg.json b/ports/apr-util/vcpkg.json index aa7937210a..7398beb9ca 100644 --- a/ports/apr-util/vcpkg.json +++ b/ports/apr-util/vcpkg.json @@ -1,12 +1,17 @@ { "name": "apr-util", "version-string": "1.6.1", - "port-version": 4, + "port-version": 5, "description": "Apache Portable Runtime (APR) project mission is to create and maintain software libraries that provide a predictable and consistent interface to underlying platform-specific implementation", "homepage": "https://apr.apache.org/", "dependencies": [ "apr", "expat", - "openssl" + "openssl", + { + "name": "vcpkg-cmake", + "host": true, + "platform": "windows" + } ] } diff --git a/versions/a-/apr-util.json b/versions/a-/apr-util.json index a2629d3852..642c2d01f6 100644 --- a/versions/a-/apr-util.json +++ b/versions/a-/apr-util.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "dfc76280690e9d419c43ee5242466de5b4e317c2", + "version-string": "1.6.1", + "port-version": 5 + }, { "git-tree": "cf1a0e97d00a5748dc58db7d0a5da0fd7d5efb66", "version-string": "1.6.1", diff --git a/versions/baseline.json b/versions/baseline.json index 8bc3d48de4..bc614aee34 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -114,7 +114,7 @@ }, "apr-util": { "baseline": "1.6.1", - "port-version": 4 + "port-version": 5 }, "apsi": { "baseline": "0.7.0",