From: Rafael Sadowski Subject: Unbreak x11/qt6/qtwebengine with libc++19 To: ports@openbsd.org Date: Sat, 19 Jul 2025 20:28:57 +0200 I would like to publish this diff before I lost ti in any dusty folder. This diff removes all dirty qtwebengine+pre-libcxx19 hacks. diff --git a/x11/qt6/qtwebengine/Makefile b/x11/qt6/qtwebengine/Makefile index d0c6a18921b..18bcbef1f00 100644 --- a/x11/qt6/qtwebengine/Makefile +++ b/x11/qt6/qtwebengine/Makefile @@ -159,9 +159,6 @@ post-patch: ${CHROMESRC}/v8/tools/run.py \ ${CHROMESRC}/tools/protoc_wrapper/protoc_wrapper.py \ ${CHROMESRC}/third_party/blink/renderer/build/scripts/run_with_pythonpath.py - # FIXME if we update base libcxx - cp /usr/include/c++/v1/__config_site \ - ${CHROMESRC}/third_party/libc++/src/include/__config_site pre-configure: cd ${CHROMESRC}/third_party/ffmpeg && \ diff --git a/x11/qt6/qtwebengine/patches/patch-cmake_Functions_cmake b/x11/qt6/qtwebengine/patches/patch-cmake_Functions_cmake index 3e09fc9e260..cb19481cb43 100644 --- a/x11/qt6/qtwebengine/patches/patch-cmake_Functions_cmake +++ b/x11/qt6/qtwebengine/patches/patch-cmake_Functions_cmake @@ -27,17 +27,7 @@ Index: cmake/Functions.cmake init_stack_vars=false is_component_build=false is_shared=true -@@ -826,7 +827,8 @@ macro(append_build_type_setup) - use_allocator_shim=false - use_partition_alloc=true - use_partition_alloc_as_malloc=false -- use_custom_libcxx=false -+ use_custom_libcxx=true -+ use_custom_libunwind=true - enable_rust=false # We do not yet support rust - ) - if(${config} STREQUAL "Debug") -@@ -879,7 +881,7 @@ macro(append_build_type_setup) +@@ -879,7 +880,7 @@ macro(append_build_type_setup) extend_gn_list(gnArgArg ARGS enable_precompiled_headers @@ -46,7 +36,7 @@ Index: cmake/Functions.cmake ) extend_gn_list(gnArgArg ARGS dcheck_always_on -@@ -962,7 +964,7 @@ macro(append_compiler_linker_sdk_setup) +@@ -962,7 +963,7 @@ macro(append_compiler_linker_sdk_setup) use_libcxx=true ) endif() @@ -55,7 +45,7 @@ Index: cmake/Functions.cmake extend_gn_list(gnArgArg ARGS use_libcxx CONDITION QT_FEATURE_stdlib_libcpp ) -@@ -1000,7 +1002,7 @@ macro(append_compiler_linker_sdk_setup) +@@ -1000,7 +1001,7 @@ macro(append_compiler_linker_sdk_setup) ) endif() get_gn_arch(cpu ${TEST_architecture_arch}) @@ -64,7 +54,7 @@ Index: cmake/Functions.cmake extend_gn_list_cflag(gnArgArg ARG arm_tune -@@ -1090,7 +1092,7 @@ macro(append_toolchain_setup) +@@ -1090,7 +1091,7 @@ macro(append_toolchain_setup) host_cpu="${cpu}" ) endif() @@ -73,7 +63,7 @@ Index: cmake/Functions.cmake get_gn_arch(cpu ${TEST_architecture_arch}) list(APPEND gnArgArg custom_toolchain="${buildDir}/target_toolchain:target" -@@ -1229,6 +1231,20 @@ function(add_gn_build_artifacts_to_target) +@@ -1229,6 +1230,20 @@ function(add_gn_build_artifacts_to_target) set_target_properties(${arg_CMAKE_TARGET} PROPERTIES LINK_DEPENDS ${arg_BUILDDIR}/${config}/${arch}/${arg_NINJA_STAMP} ) @@ -94,7 +84,7 @@ Index: cmake/Functions.cmake if(QT_IS_MACOS_UNIVERSAL) add_intermediate_archive(${target} ${arg_BUILDDIR}/${config}/${arch} ${arg_COMPLETE_STATIC}) elseif(IOS) -@@ -1355,7 +1371,7 @@ endfunction() +@@ -1355,7 +1370,7 @@ endfunction() function(check_for_ulimit) message("-- Checking 'ulimit -n'") @@ -103,7 +93,7 @@ Index: cmake/Functions.cmake OUTPUT_VARIABLE ulimitOutput ) string(REGEX MATCHALL "[0-9]+" limit "${ulimitOutput}") -@@ -1364,7 +1380,7 @@ function(check_for_ulimit) +@@ -1364,7 +1379,7 @@ function(check_for_ulimit) if(NOT ${CMAKE_VERSION} VERSION_LESS "3.21.0") message(" -- Creating linker launcher") file(GENERATE OUTPUT ${PROJECT_BINARY_DIR}/linker_ulimit.sh diff --git a/x11/qt6/qtwebengine/patches/patch-src_3rdparty_chromium_buildtools_third_party_libc++_BUILD_gn b/x11/qt6/qtwebengine/patches/patch-src_3rdparty_chromium_buildtools_third_party_libc++_BUILD_gn deleted file mode 100644 index 1487c06a8d0..00000000000 --- a/x11/qt6/qtwebengine/patches/patch-src_3rdparty_chromium_buildtools_third_party_libc++_BUILD_gn +++ /dev/null @@ -1,18 +0,0 @@ -Index: src/3rdparty/chromium/buildtools/third_party/libc++/BUILD.gn ---- src/3rdparty/chromium/buildtools/third_party/libc++/BUILD.gn.orig -+++ src/3rdparty/chromium/buildtools/third_party/libc++/BUILD.gn -@@ -69,10 +69,10 @@ target(_libcxx_target_type, "libc++") { - libs = [ "atomic" ] - } - -- inputs = [ -- "__assertion_handler", -- "__config_site", -- ] -+ #inputs = [ -+ # "__assertion_handler", -+ # "__config_site", -+ #] - - # TODO(crbug.com/1458042): Move this build file to third_party/libc++/BUILD.gn once submodule migration is done - sources = [ diff --git a/x11/qt6/qtwebengine/patches/patch-src_3rdparty_chromium_third_party_libc++_src_include___assert b/x11/qt6/qtwebengine/patches/patch-src_3rdparty_chromium_third_party_libc++_src_include___assert deleted file mode 100644 index f8e57debb3c..00000000000 --- a/x11/qt6/qtwebengine/patches/patch-src_3rdparty_chromium_third_party_libc++_src_include___assert +++ /dev/null @@ -1,19 +0,0 @@ -Index: src/3rdparty/chromium/third_party/libc++/src/include/__assert ---- src/3rdparty/chromium/third_party/libc++/src/include/__assert.orig -+++ src/3rdparty/chromium/third_party/libc++/src/include/__assert -@@ -10,12 +10,14 @@ - #ifndef _LIBCPP___ASSERT - #define _LIBCPP___ASSERT - --#include <__assertion_handler> // Note: this include is generated by CMake and is potentially vendor-provided. - #include <__config> -+#include <__verbose_abort> - - #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER) - # pragma GCC system_header - #endif -+ -+#define _LIBCPP_ASSERTION_HANDLER(message) _LIBCPP_VERBOSE_ABORT("%s", message) - - #define _LIBCPP_ASSERT(expression, message) \ - (__builtin_expect(static_cast(expression), 1) \