This is another one that knocks out a sizable chunk of the ports tree via databases/arrow/cpp. It breaks with libcxx22 because TEnumIterator doesn't have an equality operator. More recent versions have a catch.hpp that breaks the build with a static assert, so I had to disable tests.
There's been tons of changes since 0.21, although not that many in the C/C++ corner: https://thrift.apache.org/changelog Index: Makefile =================================================================== RCS file: /cvs/ports/devel/thrift/Makefile,v diff -u -p -r1.3 Makefile --- Makefile 13 Feb 2026 12:02:15 -0000 1.3 +++ Makefile 19 Aug 2026 13:58:17 -0000 @@ -1,17 +1,16 @@ COMMENT = software stack for point-to-point RPC implementation -V = 0.21.0 +V = 0.24.0 DISTNAME = thrift-${V} -REVISION = 0 CATEGORIES= devel HOMEPAGE= https://thrift.apache.org -SHARED_LIBS += thrift 0.0 # 0.0 -SHARED_LIBS += thrift_c_glib 0.0 # 0.0 -SHARED_LIBS += thrift_c_glib_zlib 0.0 # 0.0 -SHARED_LIBS += thriftz 0.0 # 0.0 +SHARED_LIBS += thrift 1.0 # 0.0 +SHARED_LIBS += thrift_c_glib 1.0 # 0.0 +SHARED_LIBS += thrift_c_glib_zlib 1.0 # 0.0 +SHARED_LIBS += thriftz 1.0 # 0.0 # Apache 2.0 PERMIT_PACKAGE= Yes @@ -28,6 +27,9 @@ CONFIGURE_ARGS = -DBUILD_SHARED_LIBS=ON -DWITH_JAVASCRIPT=OFF \ -DWITH_NODEJS=OFF +# catch.hpp shuffle triggers a static assertion on RNG validity +CONFIGURE_ARGS += -DBUILD_TESTING=OFF + MODCMAKE_POLICY_VERSION_OVERRIDE = Yes BUILD_DEPENDS = devel/boost \ @@ -37,10 +39,5 @@ RUN_DEPENDS = devel/boost LIB_DEPENDS = devel/glib2 WANTLIB += ${COMPILER_LIBCXX} c crypto glib-2.0 gobject-2.0 m WANTLIB += ssl z - -post-extract: - # file missing from usptream tarball - # cf https://github.com/apache/thrift/pull/3002#issuecomment-2441023716 - cp ${FILESDIR}/Thrift5272.thrift ${WRKSRC}/lib/cpp/test/ .include <bsd.port.mk> Index: distinfo =================================================================== RCS file: /cvs/ports/devel/thrift/distinfo,v diff -u -p -r1.1.1.1 distinfo --- distinfo 5 Nov 2024 12:20:19 -0000 1.1.1.1 +++ distinfo 19 Aug 2026 13:55:59 -0000 @@ -1,2 +1,2 @@ -SHA256 (thrift-0.21.0.tar.gz) = miTz66mkykk2AiJsFtjCKAN9s7kpHG/EAZv+O9Ofxnw= -SIZE (thrift-0.21.0.tar.gz) = 4398072 +SHA256 (thrift-0.24.0.tar.gz) = 4PpYOaTFwdYxsJMc8sVU67+k4v7jqfs//U+CzkOWxuQ= +SIZE (thrift-0.24.0.tar.gz) = 4640299 Index: files/Thrift5272.thrift =================================================================== RCS file: files/Thrift5272.thrift diff -N files/Thrift5272.thrift --- files/Thrift5272.thrift 5 Nov 2024 12:20:19 -0000 1.1.1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,11 +0,0 @@ -namespace cpp thrift5272 - -// a minimal Thrift struct, to test Trift5272.cpp -struct Meta -{ - 1: byte byte_type, // keep using byte, even it'S just an alias for i8 (THRIFT-5153) - 2: i8 i8_type, - 3: i16 i16_type, - 4: i32 i32_type, - 5: i64 i64_type, -} Index: patches/patch-lib_cpp_src_thrift_transport_TSSLSocket_cpp =================================================================== RCS file: /cvs/ports/devel/thrift/patches/patch-lib_cpp_src_thrift_transport_TSSLSocket_cpp,v diff -u -p -r1.2 patch-lib_cpp_src_thrift_transport_TSSLSocket_cpp --- patches/patch-lib_cpp_src_thrift_transport_TSSLSocket_cpp 17 Jan 2026 16:30:26 -0000 1.2 +++ patches/patch-lib_cpp_src_thrift_transport_TSSLSocket_cpp 19 Aug 2026 13:55:59 -0000 @@ -1,13 +1,16 @@ Index: lib/cpp/src/thrift/transport/TSSLSocket.cpp --- lib/cpp/src/thrift/transport/TSSLSocket.cpp.orig +++ lib/cpp/src/thrift/transport/TSSLSocket.cpp -@@ -155,15 +155,6 @@ void cleanupOpenSSL() { - CONF_modules_unload(1); +@@ -157,18 +157,6 @@ void cleanupOpenSSL() { + #endif EVP_cleanup(); CRYPTO_cleanup_all_ex_data(); -#if OPENSSL_VERSION_NUMBER >= 0x10100000 +- // Do nothing unless an openssl derivative is detected +-# if !defined(OPENSSL_IS_BORINGSSL) && !defined(OPENSSL_IS_AWSLC) - // https://www.openssl.org/docs/man1.1.1/man3/OPENSSL_thread_stop.html - OPENSSL_thread_stop(); +-# endif -#else - // ERR_remove_state() was deprecated in OpenSSL 1.0.0 and ERR_remove_thread_state() - // was deprecated in OpenSSL 1.1.0; these functions and should not be used. @@ -17,13 +20,16 @@ Index: lib/cpp/src/thrift/transport/TSSL ERR_free_strings(); mutexes.reset(); -@@ -393,15 +384,6 @@ void TSSLSocket::close() { +@@ -405,18 +393,6 @@ void TSSLSocket::close() { SSL_free(ssl_); ssl_ = nullptr; handshakeCompleted_ = false; -#if OPENSSL_VERSION_NUMBER >= 0x10100000 +- // Do nothing unless an openssl derivative is detected +-# if !defined(OPENSSL_IS_BORINGSSL) && !defined(OPENSSL_IS_AWSLC) - // https://www.openssl.org/docs/man1.1.1/man3/OPENSSL_thread_stop.html - OPENSSL_thread_stop(); +-# endif -#else - // ERR_remove_state() was deprecated in OpenSSL 1.0.0 and ERR_remove_thread_state() - // was deprecated in OpenSSL 1.1.0; these functions and should not be used. @@ -33,7 +39,7 @@ Index: lib/cpp/src/thrift/transport/TSSL } TSocket::close(); } -@@ -755,7 +737,7 @@ void TSSLSocket::authorize() { +@@ -770,7 +746,7 @@ void TSSLSocket::authorize() { if (name == nullptr) { continue; } Index: patches/patch-lib_cpp_src_thrift_transport_TServerSocket_cpp =================================================================== RCS file: /cvs/ports/devel/thrift/patches/patch-lib_cpp_src_thrift_transport_TServerSocket_cpp,v diff -u -p -r1.1.1.1 patch-lib_cpp_src_thrift_transport_TServerSocket_cpp --- patches/patch-lib_cpp_src_thrift_transport_TServerSocket_cpp 5 Nov 2024 12:20:19 -0000 1.1.1.1 +++ patches/patch-lib_cpp_src_thrift_transport_TServerSocket_cpp 19 Aug 2026 13:55:59 -0000 @@ -1,7 +1,7 @@ Index: lib/cpp/src/thrift/transport/TServerSocket.cpp --- lib/cpp/src/thrift/transport/TServerSocket.cpp.orig +++ lib/cpp/src/thrift/transport/TServerSocket.cpp -@@ -421,7 +421,7 @@ void TServerSocket::listen() { +@@ -446,7 +446,7 @@ void TServerSocket::listen() { #ifdef ANDROID AI_PASSIVE | AI_ADDRCONFIG); #else @@ -9,4 +9,4 @@ Index: lib/cpp/src/thrift/transport/TSer + AI_PASSIVE); #endif } catch (const std::system_error& e) { - GlobalOutput.printf("getaddrinfo() -> %d; %s", e.code().value(), e.what()); + TOutput::instance().printf("getaddrinfo() -> %d; %s", e.code().value(), e.what()); Index: patches/patch-lib_cpp_src_thrift_transport_TSocketUtils_h =================================================================== RCS file: /cvs/ports/devel/thrift/patches/patch-lib_cpp_src_thrift_transport_TSocketUtils_h,v diff -u -p -r1.1.1.1 patch-lib_cpp_src_thrift_transport_TSocketUtils_h --- patches/patch-lib_cpp_src_thrift_transport_TSocketUtils_h 5 Nov 2024 12:20:19 -0000 1.1.1.1 +++ patches/patch-lib_cpp_src_thrift_transport_TSocketUtils_h 19 Aug 2026 13:55:59 -0000 @@ -1,7 +1,7 @@ Index: lib/cpp/src/thrift/transport/TSocketUtils.h --- lib/cpp/src/thrift/transport/TSocketUtils.h.orig +++ lib/cpp/src/thrift/transport/TSocketUtils.h -@@ -131,7 +131,7 @@ struct AddressResolutionHelper { (public) +@@ -137,7 +137,7 @@ struct AddressResolutionHelper { (public) AddressResolutionHelper(const std::string& host, const std::string& port, // pass "25" or "smtp" for port 25 int socktype = SOCK_STREAM, @@ -10,7 +10,7 @@ Index: lib/cpp/src/thrift/transport/TSoc : gai_results(query(host, port, socktype, flags)) {} AddressResolutionHelper() = default; -@@ -146,7 +146,7 @@ struct AddressResolutionHelper { (public) +@@ -152,7 +152,7 @@ struct AddressResolutionHelper { (public) AddressResolutionHelper& resolve(const std::string& host, const std::string& port, // pass "25" or "smtp" for port 25 int socktype = SOCK_STREAM, Index: patches/patch-lib_cpp_test_CMakeLists_txt =================================================================== RCS file: patches/patch-lib_cpp_test_CMakeLists_txt diff -N patches/patch-lib_cpp_test_CMakeLists_txt --- patches/patch-lib_cpp_test_CMakeLists_txt 5 Nov 2024 12:20:19 -0000 1.1.1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,41 +0,0 @@ -no librt on OpenBSD - -Index: lib/cpp/test/CMakeLists.txt ---- lib/cpp/test/CMakeLists.txt.orig -+++ lib/cpp/test/CMakeLists.txt -@@ -133,7 +133,7 @@ target_link_libraries(TInterruptTest - ${Boost_LIBRARIES} - ) - target_link_libraries(TInterruptTest thrift) --if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT MINGW) -+if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD" AND NOT MINGW) - target_link_libraries(TInterruptTest -lrt) - endif () - add_test(NAME TInterruptTest COMMAND TInterruptTest -- "${CMAKE_CURRENT_SOURCE_DIR}/../../../test/keys") -@@ -144,7 +144,7 @@ target_link_libraries(TServerIntegrationTest - ${Boost_LIBRARIES} - ) - target_link_libraries(TServerIntegrationTest thrift) --if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT MINGW) -+if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD" AND NOT MINGW) - target_link_libraries(TServerIntegrationTest -lrt) - endif () - add_test(NAME TServerIntegrationTest COMMAND TServerIntegrationTest) -@@ -347,7 +347,7 @@ target_link_libraries(SecurityTest - ${Boost_LIBRARIES} - ) - target_link_libraries(SecurityTest thrift) --if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT MINGW) -+if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD" AND NOT MINGW) - target_link_libraries(SecurityTest -lrt) - endif () - add_test(NAME SecurityTest COMMAND SecurityTest -- "${CMAKE_CURRENT_SOURCE_DIR}/../../../test/keys") -@@ -358,7 +358,7 @@ target_link_libraries(SecurityFromBufferTest - ${Boost_LIBRARIES} - ) - target_link_libraries(SecurityFromBufferTest thrift) --if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT MINGW) -+if (NOT MSVC AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND NOT ${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD" AND NOT MINGW) - target_link_libraries(SecurityFromBufferTest -lrt) - endif () - add_test(NAME SecurityFromBufferTest COMMAND SecurityFromBufferTest -- "${CMAKE_CURRENT_SOURCE_DIR}/../../../test/keys") Index: pkg/PLIST =================================================================== RCS file: /cvs/ports/devel/thrift/pkg/PLIST,v diff -u -p -r1.1.1.1 PLIST --- pkg/PLIST 5 Nov 2024 12:20:19 -0000 1.1.1.1 +++ pkg/PLIST 19 Aug 2026 13:55:59 -0000 @@ -7,6 +7,7 @@ include/thrift/TDispatchProcessor.h include/thrift/TLogging.h include/thrift/TNonCopyable.h include/thrift/TOutput.h +include/thrift/TPrintTo.h include/thrift/TProcessor.h include/thrift/TToString.h include/thrift/TUuid.h @@ -144,7 +145,6 @@ include/thrift/windows/Sync.h include/thrift/windows/TWinsockSingleton.h include/thrift/windows/WinFcntl.h include/thrift/windows/config.h -lib/cmake/ lib/cmake/thrift/ lib/cmake/thrift/ThriftConfig.cmake lib/cmake/thrift/ThriftConfigVersion.cmake
