qt5-webengine: update to 5.15.1.

This commit is contained in:
John 2020-09-09 19:31:56 +02:00
parent 9bf73135e2
commit 92393fb750
5 changed files with 27 additions and 180 deletions

View file

@ -3,22 +3,24 @@ musl uses them for pthread_getschedparam()
source: https://git.alpinelinux.org/aports/commit/community/chromium?id=54af9f8ac24f52d382c5758e2445bf0206eff40e
--- a/src/3rdparty/chromium/services/service_manager/sandbox/linux/bpf_renderer_policy_linux.cc 2019-10-08 08:27:43.000000000 +0200
+++ - 2019-11-11 22:33:51.865153684 +0100
@@ -88,10 +88,16 @@
--- a/src/3rdparty/chromium/services/service_manager/sandbox/linux/bpf_renderer_policy_linux.cc 2020-09-01 13:02:34.000000000 +0200
+++ - 2020-09-10 19:16:13.884275822 +0200
@@ -88,11 +88,18 @@
case __NR_sysinfo:
case __NR_times:
case __NR_uname:
+#if !defined(__GLIBC__)
+ case __NR_sched_getparam:
+ case __NR_sched_getscheduler:
+ case __NR_sched_setscheduler:
+#endif
return Allow();
case __NR_sched_getaffinity:
+#if defined(__GLIBC__)
case __NR_sched_getparam:
case __NR_sched_getscheduler:
+#endif
case __NR_sched_setscheduler:
+#endif
return sandbox::RestrictSchedTarget(GetPolicyPid(), sysno);
case __NR_prlimit64:
// See crbug.com/662450 and setrlimit comment above.

View file

@ -0,0 +1,11 @@
--- qtwebengine/src/buildtools/configure.json 2020-09-01 13:02:34.000000000 +0200
+++ - 2020-09-10 16:39:33.309237834 +0200
@@ -269,7 +269,7 @@
"test": {
"include": "features.h",
"tail": [
- "#if __GLIBC__ < 2 || __GLIBC_MINOR__ < 17",
+ "#if false",
"#error glibc versions below 2.17 are not supported",
"#endif"
]

View file

@ -1,169 +0,0 @@
From 2b107e7670ffb43719a66ee4a55ab408a5dcf2a5 Mon Sep 17 00:00:00 2001
From: Ujjwal Sharma <ryzokuken@disroot.org>
Date: Wed, 22 Apr 2020 12:20:17 +0530
Subject: [PATCH] deps: V8: backport 3f8dc4b2e5ba
Original commit message:
[intl] Remove soon-to-be removed getAllFieldPositions
Needed to land ICU67.1 soon.
Bug: v8:10393
Change-Id: I3c7737ca600d6ccfdc46ffaddfb318ce60bc7618
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2136489
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#67027}
Refs: https://github.com/v8/v8/commit/3f8dc4b2e5baf77b463334c769af85b79d8c1463
---
common.gypi | 2 +-
deps/v8/src/objects/js-number-format.cc | 72 +++++++++++++------------
2 files changed, 38 insertions(+), 36 deletions(-)
diff --git a/src/3rdparty/chromium/v8/src/objects/js-number-format.cc b/src/3rdparty/chromium/v8/src/objects/js-number-format.cc
index 92d3e2fb82e..ced408aa173 100644
--- a/src/3rdparty/chromium/v8/src/objects/js-number-format.cc
+++ b/src/3rdparty/chromium/v8/src/objects/js-number-format.cc
@@ -1197,42 +1197,31 @@ MaybeHandle<JSNumberFormat> JSNumberFormat::New(Isolate* isolate,
}
namespace {
-Maybe<icu::UnicodeString> IcuFormatNumber(
+Maybe<bool> IcuFormatNumber(
Isolate* isolate,
const icu::number::LocalizedNumberFormatter& number_format,
- Handle<Object> numeric_obj, icu::FieldPositionIterator* fp_iter) {
+ Handle<Object> numeric_obj, icu::number::FormattedNumber* formatted) {
// If it is BigInt, handle it differently.
UErrorCode status = U_ZERO_ERROR;
- icu::number::FormattedNumber formatted;
if (numeric_obj->IsBigInt()) {
Handle<BigInt> big_int = Handle<BigInt>::cast(numeric_obj);
Handle<String> big_int_string;
ASSIGN_RETURN_ON_EXCEPTION_VALUE(isolate, big_int_string,
BigInt::ToString(isolate, big_int),
- Nothing<icu::UnicodeString>());
- formatted = number_format.formatDecimal(
+ Nothing<bool>());
+ *formatted = number_format.formatDecimal(
{big_int_string->ToCString().get(), big_int_string->length()}, status);
} else {
double number = numeric_obj->Number();
- formatted = number_format.formatDouble(number, status);
+ *formatted = number_format.formatDouble(number, status);
}
if (U_FAILURE(status)) {
// This happen because of icu data trimming trim out "unit".
// See https://bugs.chromium.org/p/v8/issues/detail?id=8641
- THROW_NEW_ERROR_RETURN_VALUE(isolate,
- NewTypeError(MessageTemplate::kIcuError),
- Nothing<icu::UnicodeString>());
- }
- if (fp_iter) {
- formatted.getAllFieldPositions(*fp_iter, status);
+ THROW_NEW_ERROR_RETURN_VALUE(
+ isolate, NewTypeError(MessageTemplate::kIcuError), Nothing<bool>());
}
- icu::UnicodeString result = formatted.toString(status);
- if (U_FAILURE(status)) {
- THROW_NEW_ERROR_RETURN_VALUE(isolate,
- NewTypeError(MessageTemplate::kIcuError),
- Nothing<icu::UnicodeString>());
- }
- return Just(result);
+ return Just(true);
}
} // namespace
@@ -1243,10 +1232,16 @@ MaybeHandle<String> JSNumberFormat::FormatNumeric(
Handle<Object> numeric_obj) {
DCHECK(numeric_obj->IsNumeric());
- Maybe<icu::UnicodeString> maybe_format =
- IcuFormatNumber(isolate, number_format, numeric_obj, nullptr);
+ icu::number::FormattedNumber formatted;
+ Maybe<bool> maybe_format =
+ IcuFormatNumber(isolate, number_format, numeric_obj, &formatted);
MAYBE_RETURN(maybe_format, Handle<String>());
- return Intl::ToString(isolate, maybe_format.FromJust());
+ UErrorCode status = U_ZERO_ERROR;
+ icu::UnicodeString result = formatted.toString(status);
+ if (U_FAILURE(status)) {
+ THROW_NEW_ERROR(isolate, NewTypeError(MessageTemplate::kIcuError), String);
+ }
+ return Intl::ToString(isolate, result);
}
namespace {
@@ -1359,12 +1354,18 @@ std::vector<NumberFormatSpan> FlattenRegionsToParts(
}
namespace {
-Maybe<int> ConstructParts(Isolate* isolate, const icu::UnicodeString& formatted,
- icu::FieldPositionIterator* fp_iter,
+Maybe<int> ConstructParts(Isolate* isolate,
+ icu::number::FormattedNumber* formatted,
Handle<JSArray> result, int start_index,
Handle<Object> numeric_obj, bool style_is_unit) {
+ UErrorCode status = U_ZERO_ERROR;
+ icu::UnicodeString formatted_text = formatted->toString(status);
+ if (U_FAILURE(status)) {
+ THROW_NEW_ERROR_RETURN_VALUE(
+ isolate, NewTypeError(MessageTemplate::kIcuError), Nothing<int>());
+ }
DCHECK(numeric_obj->IsNumeric());
- int32_t length = formatted.length();
+ int32_t length = formatted_text.length();
int index = start_index;
if (length == 0) return Just(index);
@@ -1373,13 +1374,14 @@ Maybe<int> ConstructParts(Isolate* isolate, const icu::UnicodeString& formatted,
// other region covers some part of the formatted string. It's possible
// there's another field with exactly the same begin and end as this backdrop,
// in which case the backdrop's field_id of -1 will give it lower priority.
- regions.push_back(NumberFormatSpan(-1, 0, formatted.length()));
+ regions.push_back(NumberFormatSpan(-1, 0, formatted_text.length()));
{
- icu::FieldPosition fp;
- while (fp_iter->next(fp)) {
- regions.push_back(NumberFormatSpan(fp.getField(), fp.getBeginIndex(),
- fp.getEndIndex()));
+ icu::ConstrainedFieldPosition cfp;
+ cfp.constrainCategory(UFIELD_CATEGORY_NUMBER);
+ while (formatted->nextPosition(cfp, status)) {
+ regions.push_back(
+ NumberFormatSpan(cfp.getField(), cfp.getStart(), cfp.getLimit()));
}
}
@@ -1401,7 +1403,7 @@ Maybe<int> ConstructParts(Isolate* isolate, const icu::UnicodeString& formatted,
Handle<String> substring;
ASSIGN_RETURN_ON_EXCEPTION_VALUE(
isolate, substring,
- Intl::ToString(isolate, formatted, part.begin_pos, part.end_pos),
+ Intl::ToString(isolate, formatted_text, part.begin_pos, part.end_pos),
Nothing<int>());
Intl::AddElement(isolate, result, index, field_type_string, substring);
++index;
@@ -1421,14 +1423,14 @@ MaybeHandle<JSArray> JSNumberFormat::FormatToParts(
number_format->icu_number_formatter().raw();
CHECK_NOT_NULL(fmt);
- icu::FieldPositionIterator fp_iter;
- Maybe<icu::UnicodeString> maybe_format =
- IcuFormatNumber(isolate, *fmt, numeric_obj, &fp_iter);
+ icu::number::FormattedNumber formatted;
+ Maybe<bool> maybe_format =
+ IcuFormatNumber(isolate, *fmt, numeric_obj, &formatted);
MAYBE_RETURN(maybe_format, Handle<JSArray>());
Handle<JSArray> result = factory->NewJSArray(0);
Maybe<int> maybe_format_to_parts = ConstructParts(
- isolate, maybe_format.FromJust(), &fp_iter, result, 0, numeric_obj,
+ isolate, &formatted, result, 0, numeric_obj,
number_format->style() == JSNumberFormat::Style::UNIT);
MAYBE_RETURN(maybe_format_to_parts, Handle<JSArray>());

View file

@ -1,14 +1,15 @@
--- a/src/buildtools/config/linux.pri 2020-03-24 10:16:30.000000000 +0100
+++ - 2020-04-06 14:42:50.189729758 +0200
@@ -190,6 +190,11 @@
} else {
--- a/src/core/config/linux.pri 2020-09-01 13:02:34.000000000 +0200
+++ - 2020-09-09 20:19:13.595622950 +0200
@@ -20,6 +20,12 @@
gn_args += use_alsa=false
}
+ qtConfig(webengine-sndio) {
+ gn_args += use_sndio=true
+ } else {
+ gn_args += use_sndio=true
+ }
+
!packagesExist(libpci): gn_args += use_libpci=false
qtConfig(webengine-ozone-x11) {

View file

@ -1,6 +1,6 @@
# Template file for 'qt5-webengine'
pkgname=qt5-webengine
version=5.15.0
version=5.15.1
revision=1
archs="x86_64* i686* armv[67]* ppc64* aarch64*"
wrksrc="qtwebengine-everywhere-src-${version}"
@ -18,16 +18,18 @@ makedepends="qt5-webchannel-devel qt5-location-devel qt5-tools-devel qt5-devel
libwebp-devel opus-devel cups-devel nss-devel minizip-devel libxslt-devel
libvpx-devel re2-devel libXtst-devel libXcursor-devel libXcomposite-devel
jsoncpp-devel harfbuzz-devel lcms2-devel protobuf-devel pulseaudio-devel
libXrandr-devel MesaLib-devel mit-krb5-devel alsa-lib-devel $(vopt_if sndio sndio-devel)"
libXrandr-devel MesaLib-devel mit-krb5-devel alsa-lib-devel libxkbcommon-devel
$(vopt_if sndio sndio-devel)"
short_desc="Cross-platform application and UI framework (QT5) - WebEngine component"
maintainer="John <me@johnnynator.dev>"
license="GPL-3.0-or-later, LGPL-3.0-or-later"
homepage="https://qt.io/"
distfiles="http://download.qt.io/official_releases/qt/${version%.*}/${version}/submodules/qtwebengine-everywhere-src-${version}.tar.xz"
checksum=c38e2fda7ed1b7d5a90f26abf231ec0715d78a5bc39a94673d8e39d75f04c5df
checksum=f903e98fe3cd717161252710125fce011cf882ced96c24968b0c38811fbefdf2
patch_args="-Np1"
build_options="sndio"
build_options_default="sndio"
if [ "$CROSS_BUILD" ]; then
hostmakedepends+=" nss-devel libevent-devel qt5-location-devel