From 20dad1facdf97c8cb6bde78a9704af995f49b87c Mon Sep 17 00:00:00 2001 From: Kai Pastor Date: Mon, 16 Jun 2025 23:04:57 +0200 Subject: [PATCH] [vcpkg baseline][qpid-proton] Update to 0.40.0, cleanup (#46016) --- ports/qpid-proton/early-cxx.diff | 31 ++++++++++++++++ ports/qpid-proton/fix-dependencies.patch | 30 ++++----------- ports/qpid-proton/portfile.cmake | 47 +++++++++--------------- ports/qpid-proton/vcpkg.json | 4 +- scripts/ci.baseline.txt | 3 -- scripts/ci.feature.baseline.txt | 3 -- versions/baseline.json | 4 +- versions/q-/qpid-proton.json | 5 +++ 8 files changed, 65 insertions(+), 62 deletions(-) create mode 100644 ports/qpid-proton/early-cxx.diff diff --git a/ports/qpid-proton/early-cxx.diff b/ports/qpid-proton/early-cxx.diff new file mode 100644 index 0000000000..0f99b959d4 --- /dev/null +++ b/ports/qpid-proton/early-cxx.diff @@ -0,0 +1,31 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 2e928ef..29e3d79 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -19,7 +19,7 @@ + + cmake_minimum_required (VERSION 3.16) + +-project (Proton C) ++project (Proton C CXX) + + set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/tools/cmake/Modules") + set (CMAKE_THREAD_PREFER_PTHREAD TRUE) +@@ -75,8 +75,7 @@ set(UNSET_CMAKE_CXX_COMPILER OFF) + if (NOT DEFINED CMAKE_CXX_COMPILER) + set(UNSET_CMAKE_CXX_COMPILER ON) + endif () +-check_language (CXX) +-if (CMAKE_CXX_COMPILER) ++if(0) + if (UNSET_CMAKE_CXX_COMPILER) + # https://gitlab.kitware.com/cmake/cmake/-/issues/25535: check_language might set the variable incorrectly + unset(CMAKE_CXX_COMPILER) +@@ -84,6 +83,7 @@ if (CMAKE_CXX_COMPILER) + endif () + + enable_language(CXX) ++else() + + set(CMAKE_CXX_STANDARD 17) + set(CMAKE_CXX_EXTENSIONS OFF) diff --git a/ports/qpid-proton/fix-dependencies.patch b/ports/qpid-proton/fix-dependencies.patch index dfc5985fcc..8b040ea163 100644 --- a/ports/qpid-proton/fix-dependencies.patch +++ b/ports/qpid-proton/fix-dependencies.patch @@ -1,8 +1,8 @@ diff --git a/c/CMakeLists.txt b/c/CMakeLists.txt -index 27b40e7..81de970 100644 +index e444098..451277f 100644 --- a/c/CMakeLists.txt +++ b/c/CMakeLists.txt -@@ -377,8 +377,13 @@ if (PROACTOR STREQUAL "iocp" OR (NOT PROACTOR AND NOT PROACTOR_OK)) +@@ -378,8 +378,13 @@ if (PROACTOR STREQUAL "iocp" OR (NOT PROACTOR AND NOT PROACTOR_OK)) endif() if (PROACTOR STREQUAL "libuv" OR (NOT PROACTOR AND NOT PROACTOR_OK)) @@ -17,18 +17,6 @@ index 27b40e7..81de970 100644 set (PROACTOR_OK libuv) set (qpid-proton-proactor src/proactor/libuv.c ${qpid-proton-proactor-common}) set (PROACTOR_LIBS Libuv::Libuv) -@@ -727,11 +732,6 @@ install (FILES - ${CMAKE_CURRENT_BINARY_DIR}/ProtonConfig.cmake - ${CMAKE_CURRENT_BINARY_DIR}/ProtonConfigVersion.cmake - DESTINATION ${LIB_INSTALL_DIR}/cmake/Proton) --install (FILES -- ../tools/cmake/Modules/FindCyrusSASL.cmake -- ../tools/cmake/Modules/FindOpenSSL.cmake -- ../tools/cmake/Modules/FindThreads.cmake -- DESTINATION ${LIB_INSTALL_DIR}/cmake/Proton) - - if (ENABLE_BENCHMARKS) - add_subdirectory(benchmarks) diff --git a/c/src/ProtonConfig.cmake.in b/c/src/ProtonConfig.cmake.in index 3eca7bc..fe27234 100644 --- a/c/src/ProtonConfig.cmake.in @@ -54,22 +42,20 @@ index 3eca7bc..fe27234 100644 set(CyrusSASL_FOUND @CyrusSASL_FOUND@) if (CyrusSASL_FOUND) diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt -index 2049fe9..3dc8a06 100644 +index c65cc87..0d9f485 100644 --- a/cpp/CMakeLists.txt +++ b/cpp/CMakeLists.txt -@@ -26,10 +26,10 @@ find_package(Threads) +@@ -38,7 +38,9 @@ list(APPEND PLATFORM_LIBS Threads::Threads) include(versions.cmake) # Check for JSON-CPP support for connection configuration -find_package(JsonCpp) ++find_package(JsonCpp NAMES jsoncpp CONFIG REQUIRED) ++set(JsonCpp_INCLUDE_DIRS "") ++set(JsonCpp_LIBRARY JsonCpp::JsonCpp) option(ENABLE_JSONCPP "Use jsoncpp parser for connection configuration" ${JsonCpp_FOUND}) if (ENABLE_JSONCPP) -- include_directories(${JsonCpp_INCLUDE_DIRS}) -+ find_package(JsonCpp NAMES jsoncpp CONFIG REQUIRED) -+ set(JsonCpp_LIBRARY JsonCpp::JsonCpp) - set(CONNECT_CONFIG_SRC src/connect_config.cpp) - set(CONNECT_CONFIG_LIBS ${JsonCpp_LIBRARY}) - else() + include_directories(${JsonCpp_INCLUDE_DIRS}) diff --git a/cpp/ProtonCppConfig.cmake.in b/cpp/ProtonCppConfig.cmake.in index aaa1bf9..e1be025 100644 --- a/cpp/ProtonCppConfig.cmake.in diff --git a/ports/qpid-proton/portfile.cmake b/ports/qpid-proton/portfile.cmake index 57bcf237c1..20a5f9a60d 100644 --- a/ports/qpid-proton/portfile.cmake +++ b/ports/qpid-proton/portfile.cmake @@ -4,30 +4,25 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO apache/qpid-proton REF "${VERSION}" - SHA512 05c3fded3db1fae0e6a7b9fbe34fe17af41a676a584ee916cbbeb82e957d7da74861524c5db06634326c403fabc82fddf938d018d9383745a6ce0cbc7a9eada3 + SHA512 ce24a92d623c9e56666128e243bc58acdbff8f7dfac1f728fdbd97a2c3ec21135b8c2a79c3e13920ca0d52545819766b90fc6aca35318b754eedf5ae5329ff36 HEAD_REF next PATCHES + early-cxx.diff fix-dependencies.patch ) -file(REMOVE "${SOURCE_PATH}/tools/cmake/Modules/FindPython.cmake") -file(REMOVE "${SOURCE_PATH}/tools/cmake/Modules/FindOpenSSL.cmake") -file(REMOVE "${SOURCE_PATH}/tools/cmake/Modules/FindJsonCpp.cmake") - vcpkg_find_acquire_program(PYTHON3) -if(VCPKG_TARGET_IS_OSX OR VCPKG_TARGET_IS_IOS) - set(rpath "@loader_path") -else() - set(rpath "\$ORIGIN") -endif() vcpkg_cmake_configure( SOURCE_PATH "${SOURCE_PATH}" - DISABLE_PARALLEL_CONFIGURE # It may cause call CHECK_LIBRARY_EXISTS before call project to set the language OPTIONS -DBUILD_BINDINGS=cpp + -DBUILD_EXAMPLES=OFF + -DBUILD_TESTING=OFF -DCMAKE_DISABLE_FIND_PACKAGE_CyrusSASL=ON -DCMAKE_DISABLE_FIND_PACKAGE_Doxygen=ON + -DCMAKE_DISABLE_FIND_PACKAGE_OpenSSL=${VCPKG_TARGET_IS_WINDOWS} # match dependencies + -DCMAKE_DISABLE_FIND_PACKAGE_opentelemetry-cpp=ON -DCMAKE_DISABLE_FIND_PACKAGE_SWIG=ON -DENABLE_JSONCPP=ON -DENABLE_LINKTIME_OPTIMIZATION=OFF @@ -36,34 +31,26 @@ vcpkg_cmake_configure( -DENABLE_WARNING_ERROR=OFF -DENABLE_BENCHMARKS=OFF -DENABLE_FUZZ_TESTING=OFF - -DBUILD_EXAMPLES=OFF - -DBUILD_TESTING=OFF - -DCMAKE_INSTALL_RPATH=${rpath} - -DPython_EXECUTABLE=${PYTHON3} + "-DPython_EXECUTABLE=${PYTHON3}" + -DVCPKG_LOCK_FIND_PACKAGE_Libuv=${VCPKG_TARGET_IS_OSX} # match dependencies + MAYBE_UNUSED_VARIABLES + VCPKG_LOCK_FIND_PACKAGE_Libuv ) vcpkg_cmake_install() vcpkg_copy_pdbs() - -# qpid-proton installs tests into share/proton; this is not desireable -file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share/proton") - -vcpkg_cmake_config_fixup( - PACKAGE_NAME proton - CONFIG_PATH lib/cmake/Proton - DO_NOT_DELETE_PARENT_CONFIG_PATH -) -vcpkg_cmake_config_fixup( - PACKAGE_NAME protoncpp - CONFIG_PATH lib/cmake/ProtonCpp -) vcpkg_fixup_pkgconfig() +vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/ProtonCpp" PACKAGE_NAME "protoncpp" DO_NOT_DELETE_PARENT_CONFIG_PATH) +vcpkg_cmake_config_fixup(CONFIG_PATH "lib/cmake/Proton" PACKAGE_NAME "proton") + file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" "${CURRENT_PACKAGES_DIR}/debug/share" + "${CURRENT_PACKAGES_DIR}/share/proton/CMakeLists.txt" + "${CURRENT_PACKAGES_DIR}/share/proton/FindCyrusSASL.cmake" + "${CURRENT_PACKAGES_DIR}/share/proton/examples" + "${CURRENT_PACKAGES_DIR}/share/proton/tests" ) -vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/proton/version.h" "#define PN_INSTALL_PREFIX \"${CURRENT_PACKAGES_DIR}\"" "" IGNORE_UNCHANGED) - vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE.txt") diff --git a/ports/qpid-proton/vcpkg.json b/ports/qpid-proton/vcpkg.json index 48c080e605..9a22164b85 100644 --- a/ports/qpid-proton/vcpkg.json +++ b/ports/qpid-proton/vcpkg.json @@ -1,10 +1,10 @@ { "name": "qpid-proton", - "version": "0.38.0", - "port-version": 2, + "version": "0.40.0", "description": "Qpid Proton is a high-performance, lightweight messaging library.", "homepage": "https://github.com/apache/qpid-proton", "license": "Apache-2.0", + "supports": "!(static & staticcrt) & !uwp", "dependencies": [ "jsoncpp", { diff --git a/scripts/ci.baseline.txt b/scripts/ci.baseline.txt index 54c1e2adbc..2d778f48d5 100644 --- a/scripts/ci.baseline.txt +++ b/scripts/ci.baseline.txt @@ -800,9 +800,6 @@ popsift:x64-windows=fail python2:arm-neon-android=fail python2:arm64-android=fail python2:x64-android=fail -qpid-proton:arm64-uwp=fail -qpid-proton:x64-uwp=fail -qpid-proton:x64-windows-static=fail qt-advanced-docking-system:arm-neon-android=fail qt-advanced-docking-system:arm64-android=fail qt-advanced-docking-system:x64-android=fail diff --git a/scripts/ci.feature.baseline.txt b/scripts/ci.feature.baseline.txt index fd218a5498..c9d6b2e8d7 100644 --- a/scripts/ci.feature.baseline.txt +++ b/scripts/ci.feature.baseline.txt @@ -397,9 +397,6 @@ popsift:x64-windows-static-md=fail portable-snippets:arm-uwp=fail qbittorrent:x64-linux=fail # Not yet ready for these platforms. qbittorrent:x64-osx=fail # Not yet ready for these platforms. -qpid-proton:arm-uwp=fail -qpid-proton:x64-uwp=fail -qpid-proton:x64-windows-static=fail qt-advanced-docking-system(android)=fail qt5-base:arm64-windows=fail qt5-canvas3d=skip # Skip deprecated Qt module (remove after 1 year or longer due to vcpkg upgrade not handling removed ports correctly) diff --git a/versions/baseline.json b/versions/baseline.json index 6c38076540..5826bf5eac 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -7629,8 +7629,8 @@ "port-version": 0 }, "qpid-proton": { - "baseline": "0.38.0", - "port-version": 2 + "baseline": "0.40.0", + "port-version": 0 }, "qscintilla": { "baseline": "2.14.1", diff --git a/versions/q-/qpid-proton.json b/versions/q-/qpid-proton.json index 8d613e7dab..4bf70f1084 100644 --- a/versions/q-/qpid-proton.json +++ b/versions/q-/qpid-proton.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "fa587ba9e7e884370056a0c9cd66f9a634a3af4a", + "version": "0.40.0", + "port-version": 0 + }, { "git-tree": "2cf3ce91a7b7d428dece244d6626ebb67d03a37d", "version": "0.38.0",