diff options
| -rw-r--r-- | meta/recipes-sato/webkit/webkitgtk/0001-Cherry-pick-292304-main-7ffc29624258-.-https-bugs.we.patch | 75 | ||||
| -rw-r--r-- | meta/recipes-sato/webkit/webkitgtk/0001-EnumTraits.h-error-no-matching-function-for-call-to-.patch | 77 | ||||
| -rw-r--r-- | meta/recipes-sato/webkit/webkitgtk_2.48.1.bb (renamed from meta/recipes-sato/webkit/webkitgtk_2.48.0.bb) | 4 |
3 files changed, 1 insertions, 155 deletions
diff --git a/meta/recipes-sato/webkit/webkitgtk/0001-Cherry-pick-292304-main-7ffc29624258-.-https-bugs.we.patch b/meta/recipes-sato/webkit/webkitgtk/0001-Cherry-pick-292304-main-7ffc29624258-.-https-bugs.we.patch deleted file mode 100644 index 5cbb1035b2..0000000000 --- a/meta/recipes-sato/webkit/webkitgtk/0001-Cherry-pick-292304-main-7ffc29624258-.-https-bugs.we.patch +++ /dev/null | |||
| @@ -1,75 +0,0 @@ | |||
| 1 | From 83093455d02d73a327cea502d974aac82b59ad17 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Adrian Perez de Castro <aperez@igalia.com> | ||
| 3 | Date: Tue, 18 Mar 2025 07:39:01 -0700 | ||
| 4 | Subject: [PATCH] Cherry-pick 292304@main (7ffc29624258). | ||
| 5 | https://bugs.webkit.org/show_bug.cgi?id=289953 | ||
| 6 | |||
| 7 | [GTK][WPE] Use _LIBCPP_HARDENING_MODE with newer libc++ versions | ||
| 8 | https://bugs.webkit.org/show_bug.cgi?id=289953 | ||
| 9 | |||
| 10 | Reviewed by Alicia Boya Garcia. | ||
| 11 | |||
| 12 | * Source/cmake/OptionsCommon.cmake: Add a new check for the libc++ | ||
| 13 | version, if it is 19 or newer, use the new _LIBCPP_HARDENING_MODE | ||
| 14 | macro, otherwise for older versions keep _LIBCPP_ENABLE_ASSERTIONS. | ||
| 15 | |||
| 16 | Canonical link: https://commits.webkit.org/292304@main | ||
| 17 | |||
| 18 | Upstream-Status: Backport [https://github.com/WebKit/WebKit/commit/2c105443d41e5ce3de3a4cac2ed8a07ebd134459] | ||
| 19 | |||
| 20 | Canonical link: https://commits.webkit.org/290945.71@webkitglib/2.48 | ||
| 21 | |||
| 22 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 23 | --- | ||
| 24 | Source/cmake/OptionsCommon.cmake | 24 +++++++++++++++++++----- | ||
| 25 | 1 file changed, 19 insertions(+), 5 deletions(-) | ||
| 26 | |||
| 27 | diff --git a/Source/cmake/OptionsCommon.cmake b/Source/cmake/OptionsCommon.cmake | ||
| 28 | index f6cf5ee..3178674 100644 | ||
| 29 | --- a/Source/cmake/OptionsCommon.cmake | ||
| 30 | +++ b/Source/cmake/OptionsCommon.cmake | ||
| 31 | @@ -229,8 +229,22 @@ set(CXX_STDLIB_TEST_SOURCE " | ||
| 32 | ") | ||
| 33 | check_cxx_source_compiles("${CXX_STDLIB_TEST_SOURCE}" CXX_STDLIB_IS_LIBCPP) | ||
| 34 | if (CXX_STDLIB_IS_LIBCPP) | ||
| 35 | - set(CXX_STDLIB_VARIANT "LIBCPP") | ||
| 36 | - set(CXX_STDLIB_ASSERTIONS_MACRO _LIBCPP_ENABLE_ASSERTIONS) | ||
| 37 | + set(CXX_STDLIB_TEST_SOURCE " | ||
| 38 | + #include <utility> | ||
| 39 | + #if _LIBCPP_VERSION >= 190000 | ||
| 40 | + int main() { } | ||
| 41 | + #else | ||
| 42 | + #error libc++ is older than 19.x | ||
| 43 | + #endif | ||
| 44 | + ") | ||
| 45 | + check_cxx_source_compiles("${CXX_STDLIB_TEST_SOURCE}" CXX_STDLIB_IS_LIBCPP_19_OR_NEWER) | ||
| 46 | + if (CXX_STDLIB_IS_LIBCPP_19_OR_NEWER) | ||
| 47 | + set(CXX_STDLIB_VARIANT "LIBCPP 19+") | ||
| 48 | + set(CXX_STDLIB_ASSERTIONS_MACRO _LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_EXTENSIVE) | ||
| 49 | + else () | ||
| 50 | + set(CXX_STDLIB_VARIANT "LIBCPP <19") | ||
| 51 | + set(CXX_STDLIB_ASSERTIONS_MACRO _LIBCPP_ENABLE_ASSERTIONS=1) | ||
| 52 | + endif () | ||
| 53 | else () | ||
| 54 | set(CXX_STDLIB_TEST_SOURCE " | ||
| 55 | #include <utility> | ||
| 56 | @@ -239,7 +253,7 @@ else () | ||
| 57 | check_cxx_source_compiles("${CXX_STDLIB_TEST_SOURCE}" CXX_STDLIB_IS_GLIBCXX) | ||
| 58 | if (CXX_STDLIB_IS_GLIBCXX) | ||
| 59 | set(CXX_STDLIB_VARIANT "GLIBCXX") | ||
| 60 | - set(CXX_STDLIB_ASSERTIONS_MACRO _GLIBCXX_ASSERTIONS) | ||
| 61 | + set(CXX_STDLIB_ASSERTIONS_MACRO _GLIBCXX_ASSERTIONS=1) | ||
| 62 | endif () | ||
| 63 | endif () | ||
| 64 | message(STATUS "C++ standard library in use: ${CXX_STDLIB_VARIANT}") | ||
| 65 | @@ -255,8 +269,8 @@ option(USE_CXX_STDLIB_ASSERTIONS | ||
| 66 | |||
| 67 | if (USE_CXX_STDLIB_ASSERTIONS) | ||
| 68 | if (CXX_STDLIB_ASSERTIONS_MACRO) | ||
| 69 | - message(STATUS " Assertions enabled, ${CXX_STDLIB_ASSERTIONS_MACRO}=1") | ||
| 70 | - add_compile_definitions("${CXX_STDLIB_ASSERTIONS_MACRO}=1") | ||
| 71 | + message(STATUS " Assertions enabled, ${CXX_STDLIB_ASSERTIONS_MACRO}") | ||
| 72 | + add_compile_definitions("${CXX_STDLIB_ASSERTIONS_MACRO}") | ||
| 73 | else () | ||
| 74 | message(STATUS " Assertions disabled, CXX_STDLIB_ASSERTIONS_MACRO undefined") | ||
| 75 | endif () | ||
diff --git a/meta/recipes-sato/webkit/webkitgtk/0001-EnumTraits.h-error-no-matching-function-for-call-to-.patch b/meta/recipes-sato/webkit/webkitgtk/0001-EnumTraits.h-error-no-matching-function-for-call-to-.patch deleted file mode 100644 index 5b83d9e7eb..0000000000 --- a/meta/recipes-sato/webkit/webkitgtk/0001-EnumTraits.h-error-no-matching-function-for-call-to-.patch +++ /dev/null | |||
| @@ -1,77 +0,0 @@ | |||
| 1 | From 7d159a631ae55c10a0b7a92cf031200a11629736 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Fujii Hironori <Hironori.Fujii@sony.com> | ||
| 3 | Date: Tue, 18 Mar 2025 10:25:47 +0900 | ||
| 4 | Subject: [PATCH] EnumTraits.h: error: no matching function for call to | ||
| 5 | 'enumName' with Clang 20 https://bugs.webkit.org/show_bug.cgi?id=289669 | ||
| 6 | |||
| 7 | Reviewed by NOBODY (OOPS!). | ||
| 8 | |||
| 9 | Clang 20 couldn't compile EnumTraits.h. | ||
| 10 | |||
| 11 | > wtf/EnumTraits.h:212:33: note: candidate template ignored: invalid explicitly-specified argument for template parameter 'V' | ||
| 12 | |||
| 13 | An invalid enum value can't be specifed to the template parameter `V`. | ||
| 14 | |||
| 15 | > template<auto V> constexpr std::span<const char> enumName() | ||
| 16 | |||
| 17 | The upstream Magic Enum C++ has a template variable `is_enum_constexpr_static_cast_valid<E, V>` to check a enum value is valid. | ||
| 18 | <https://github.com/Neargye/magic_enum/blob/a413fcc9c46a020a746907136a384c227f3cd095/include/magic_enum/magic_enum.hpp#L624-L634> | ||
| 19 | |||
| 20 | Imported the template variable. | ||
| 21 | |||
| 22 | * Source/WTF/wtf/EnumTraits.h: | ||
| 23 | (WTF::enumName): | ||
| 24 | (WTF::makeEnumNames): | ||
| 25 | |||
| 26 | Upstream-Status: Submitted [https://github.com/WebKit/WebKit/pull/42597] | ||
| 27 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 28 | --- | ||
| 29 | Source/WTF/wtf/EnumTraits.h | 21 ++++++++++++++++++++- | ||
| 30 | 1 file changed, 20 insertions(+), 1 deletion(-) | ||
| 31 | |||
| 32 | diff --git a/Source/WTF/wtf/EnumTraits.h b/Source/WTF/wtf/EnumTraits.h | ||
| 33 | index 0d33e39a..95e6318b 100644 | ||
| 34 | --- a/Source/WTF/wtf/EnumTraits.h | ||
| 35 | +++ b/Source/WTF/wtf/EnumTraits.h | ||
| 36 | @@ -152,6 +152,16 @@ constexpr bool isZeroBasedContiguousEnum() | ||
| 37 | #pragma clang diagnostic ignored "-Wenum-constexpr-conversion" | ||
| 38 | #endif | ||
| 39 | |||
| 40 | +#if COMPILER(CLANG) && __clang_major__ >= 16 | ||
| 41 | +template <typename E, auto V, typename = void> | ||
| 42 | +inline constexpr bool isEnumConstexprStaticCastValid = false; | ||
| 43 | +template <typename E, auto V> | ||
| 44 | +inline constexpr bool isEnumConstexprStaticCastValid<E, V, std::void_t<std::integral_constant<E, static_cast<E>(V)>>> = true; | ||
| 45 | +#else | ||
| 46 | +template <typename, auto> | ||
| 47 | +inline constexpr bool isEnumConstexprStaticCastValid = true; | ||
| 48 | +#endif | ||
| 49 | + | ||
| 50 | template<typename E> | ||
| 51 | constexpr std::span<const char> enumTypeNameImpl() | ||
| 52 | { | ||
| 53 | @@ -215,6 +225,15 @@ constexpr std::span<const char> enumName() | ||
| 54 | return result; | ||
| 55 | } | ||
| 56 | |||
| 57 | +template<typename E, auto V> | ||
| 58 | +constexpr std::span<const char> enumName() | ||
| 59 | +{ | ||
| 60 | + if constexpr (isEnumConstexprStaticCastValid<E, V>) | ||
| 61 | + return enumName<static_cast<E>(V)>(); | ||
| 62 | + else | ||
| 63 | + return { }; | ||
| 64 | +} | ||
| 65 | + | ||
| 66 | template<typename E> | ||
| 67 | constexpr std::underlying_type_t<E> enumNamesMin() | ||
| 68 | { | ||
| 69 | @@ -264,7 +283,7 @@ constexpr auto makeEnumNames(std::index_sequence<Is...>) | ||
| 70 | { | ||
| 71 | constexpr auto min = enumNamesMin<E>(); | ||
| 72 | return std::array<std::span<const char>, sizeof...(Is)> { | ||
| 73 | - enumName<static_cast<E>(static_cast<std::underlying_type_t<E>>(Is) + min)>()... | ||
| 74 | + enumName<E, static_cast<std::underlying_type_t<E>>(Is) + min>()... | ||
| 75 | }; | ||
| 76 | } | ||
| 77 | |||
diff --git a/meta/recipes-sato/webkit/webkitgtk_2.48.0.bb b/meta/recipes-sato/webkit/webkitgtk_2.48.1.bb index 58b78b5f28..58d0a11202 100644 --- a/meta/recipes-sato/webkit/webkitgtk_2.48.0.bb +++ b/meta/recipes-sato/webkit/webkitgtk_2.48.1.bb | |||
| @@ -16,12 +16,10 @@ SRC_URI = "https://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \ | |||
| 16 | file://no-musttail-arm.patch \ | 16 | file://no-musttail-arm.patch \ |
| 17 | file://t6-not-declared.patch \ | 17 | file://t6-not-declared.patch \ |
| 18 | file://sys_futex.patch \ | 18 | file://sys_futex.patch \ |
| 19 | file://0001-EnumTraits.h-error-no-matching-function-for-call-to-.patch \ | ||
| 20 | file://0001-Cherry-pick-292304-main-7ffc29624258-.-https-bugs.we.patch \ | ||
| 21 | file://0001-Fix-build-errors-on-RISCV-https-bugs.webkit.org-show.patch \ | 19 | file://0001-Fix-build-errors-on-RISCV-https-bugs.webkit.org-show.patch \ |
| 22 | file://fix-ftbfs-riscv64.patch \ | 20 | file://fix-ftbfs-riscv64.patch \ |
| 23 | " | 21 | " |
| 24 | SRC_URI[sha256sum] = "94904a55cf12d44a4e36ceadafff02d46da73d76be9b4769f34cbfdf0eebf88e" | 22 | SRC_URI[sha256sum] = "98efdf21c4cdca0fe0b73ab5a8cb52093b5aa52d9b1b016a93f71dbfa1eb258f" |
| 25 | 23 | ||
| 26 | inherit cmake pkgconfig gobject-introspection perlnative features_check upstream-version-is-even gi-docgen | 24 | inherit cmake pkgconfig gobject-introspection perlnative features_check upstream-version-is-even gi-docgen |
| 27 | 25 | ||
