firefox: update to 84.0.

This commit is contained in:
Johannes 2020-12-15 23:00:19 +01:00 committed by Daniel Kolesa
parent 2c92e21f50
commit d8a9f0832f
5 changed files with 55 additions and 166 deletions

View file

@ -1,65 +0,0 @@
this is still experimental in rust-1.46 for arm and aarch64
--- gfx/qcms/src/lib.rs.orig 2020-11-17 22:03:09.868746869 +0100
+++ gfx/qcms/src/lib.rs 2020-11-17 22:03:27.795605120 +0100
@@ -47,8 +47,8 @@
pub mod transform;
#[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
pub mod transform_avx;
-#[cfg(any(target_arch = "aarch64", target_arch = "arm"))]
-pub mod transform_neon;
+//#[cfg(any(target_arch = "aarch64", target_arch = "arm"))]
+//pub mod transform_neon;
#[cfg(any(target_arch = "x86", target_arch = "x86_64"))]
pub mod transform_sse2;
pub mod transform_util;
--- gfx/qcms/src/transform.rs.orig 2020-11-17 22:15:03.413104913 +0100
+++ gfx/qcms/src/transform.rs 2020-11-17 22:15:17.128996464 +0100
@@ -21,11 +21,11 @@
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#[cfg(any(target_arch = "arm", target_arch = "aarch64"))]
-use crate::transform_neon::{
- qcms_transform_data_bgra_out_lut_neon, qcms_transform_data_rgb_out_lut_neon,
- qcms_transform_data_rgba_out_lut_neon,
-};
+//#[cfg(any(target_arch = "arm", target_arch = "aarch64"))]
+//use crate::transform_neon::{
+// qcms_transform_data_bgra_out_lut_neon, qcms_transform_data_rgb_out_lut_neon,
+// qcms_transform_data_rgba_out_lut_neon,
+//};
use crate::{
chain::qcms_chain_transform,
double_to_s15Fixed16Number,
@@ -1424,18 +1424,18 @@
(*transform).transform_fn = Some(qcms_transform_data_bgra_out_lut_sse2)
}
}
- } else if cfg!(any(target_arch = "arm", target_arch = "aarch64")) && qcms_supports_neon
- {
- #[cfg(any(target_arch = "arm", target_arch = "aarch64"))]
- {
- if in_type == QCMS_DATA_RGB_8 {
- (*transform).transform_fn = Some(qcms_transform_data_rgb_out_lut_neon)
- } else if in_type == QCMS_DATA_RGBA_8 {
- (*transform).transform_fn = Some(qcms_transform_data_rgba_out_lut_neon)
- } else if in_type == QCMS_DATA_BGRA_8 {
- (*transform).transform_fn = Some(qcms_transform_data_bgra_out_lut_neon)
- }
- }
+ // } else if cfg!(any(target_arch = "arm", target_arch = "aarch64")) && qcms_supports_neon
+ // {
+ // #[cfg(any(target_arch = "arm", target_arch = "aarch64"))]
+ // {
+ // if in_type == QCMS_DATA_RGB_8 {
+ // (*transform).transform_fn = Some(qcms_transform_data_rgb_out_lut_neon)
+ // } else if in_type == QCMS_DATA_RGBA_8 {
+ // (*transform).transform_fn = Some(qcms_transform_data_rgba_out_lut_neon)
+ // } else if in_type == QCMS_DATA_BGRA_8 {
+ // (*transform).transform_fn = Some(qcms_transform_data_bgra_out_lut_neon)
+ // }
+ // }
} else if in_type == QCMS_DATA_RGB_8 {
(*transform).transform_fn = Some(qcms_transform_data_rgb_out_lut_precache)
} else if in_type == QCMS_DATA_RGBA_8 {

View file

@ -6,19 +6,19 @@ instead use what is set in RUST_TARGET
Skip extra checks on cross builds (broken for arm*)
--- build/moz.configure/rust.configure.orig 2019-10-17 04:19:59.000000000 +0700
+++ build/moz.configure/rust.configure 2019-10-22 11:48:55.616022140 +0700
@@ -81,9 +81,6 @@
--- build/moz.configure/rust.configure 2020-12-12 01:35:33.000000000 +0100
+++ build/moz.configure/rust.configure 2020-12-15 19:45:16.467750787 +0100
@@ -91,9 +91,6 @@
return unwrap
-rustc = unwrap_rustup(rustc, 'rustc')
-cargo = unwrap_rustup(cargo, 'cargo')
-rustc = unwrap_rustup(rustc, "rustc")
-cargo = unwrap_rustup(cargo, "cargo")
-
set_config('CARGO', cargo)
set_config('RUSTC', rustc)
@@ -225,7 +222,9 @@
set_config("CARGO", cargo)
set_config("RUSTC", rustc)
@@ -260,7 +257,9 @@
data.setdefault(key, []).append(namespace(rust_target=t, target=info))
return data
@ -26,10 +26,10 @@ Skip extra checks on cross builds (broken for arm*)
+@imports('os')
+@imports(_from='mozbuild.util', _import='ensure_unicode')
+@imports(_from='mozbuild.util', _import='system_encoding')
def detect_rustc_target(host_or_target, compiler_info, arm_target, rust_supported_targets):
# Rust's --target options are similar to, but not exactly the same
# as, the autoconf-derived targets we use. An example would be that
@@ -340,13 +339,13 @@
def detect_rustc_target(
host_or_target, compiler_info, arm_target, rust_supported_targets
):
@@ -382,12 +381,12 @@
return None
@ -37,50 +37,60 @@ Skip extra checks on cross builds (broken for arm*)
+ rustc_target = os.environ['RUST_TARGET']
if rustc_target is None:
die("Don't know how to translate {} for rustc".format(
host_or_target.alias))
die("Don't know how to translate {} for rustc".format(host_or_target.alias))
- return rustc_target
+ return ensure_unicode(rustc_target, system_encoding)
@imports('os')
@@ -369,26 +368,6 @@
@imports("os")
@@ -410,35 +409,6 @@
os.write(in_fd, ensure_binary(source))
os.close(in_fd)
-
- cmd = [
- rustc,
- '--crate-type', 'staticlib',
- "--crate-type",
- "staticlib",
- target_arg,
- '-o', out_path,
- "-o",
- out_path,
- in_path,
- ]
-
- def failed():
- die(dedent('''\
- die(
- dedent(
- """\
- Cannot compile for {} with {}
- The target may be unsupported, or you may not have
- a rust std library for that target installed. Try:
-
- rustup target add {}
- '''.format(host_or_target.alias, rustc, rustc_target)))
- """.format(
- host_or_target.alias, rustc, rustc_target
- )
- )
- )
-
- check_cmd_output(*cmd, onerror=failed)
- if not os.path.exists(out_path) or os.path.getsize(out_path) == 0:
- failed()
finally:
os.remove(in_path)
os.remove(out_path)
@@ -403,20 +382,7 @@
rustc_target = detect_rustc_target(host, compiler_info, arm_target,
rust_supported_targets)
@@ -462,28 +432,7 @@
host, compiler_info, arm_target, rust_supported_targets
)
if rustc_target != rustc_host:
- if host.alias == rustc_target:
- configure_host = host.alias
- else:
- configure_host = '{}/{}'.format(host.alias, rustc_target)
- die(dedent('''\
- configure_host = "{}/{}".format(host.alias, rustc_target)
- die(
- dedent(
- """\
- The rust compiler host ({rustc}) is not suitable for the configure host ({configure}).
-
- You can solve this by:
@ -88,9 +98,15 @@ Skip extra checks on cross builds (broken for arm*)
- mozconfig and adding "ac_add_options --host={rustc}".
- * Or, install the rust toolchain for {configure}, if supported, by running
- "rustup default stable-{rustc_target}"
- '''.format(rustc=rustc_host, configure=configure_host, rustc_target=rustc_target)))
- """.format(
- rustc=rustc_host,
- configure=configure_host,
- rustc_target=rustc_target,
- )
- )
- )
- assert_rust_compile(host, rustc_target, rustc)
+ return rustc_host
return rustc_target
@depends(rustc, target, c_compiler, rust_supported_targets, arm_target, when=rust_compiler)

View file

@ -42,11 +42,11 @@
if CONFIG['OS_TARGET'] == 'Darwin':
--- build/moz.configure/old.configure 2020-06-30 12:17:04.087609070 +0200
+++ - 2020-06-30 12:18:26.027756310 +0200
@@ -210,6 +210,7 @@
@@ -88,6 +88,7 @@
@old_configure_options(
'--cache-file',
'--datadir',
+ '--enable-sndio',
'--enable-crashreporter',
'--enable-dbus',
'--enable-debug-js-modules',
"--cache-file",
"--datadir",
+ "--enable-sndio",
"--enable-crashreporter",
"--enable-dbus",
"--enable-debug-js-modules",

View file

@ -1,62 +0,0 @@
From 71597faac0fde4f608a60dd610d0cefac4972cc3 Mon Sep 17 00:00:00 2001
From: Jonathan Wakely <jwakely@redhat.com>
Date: Tue, 17 Nov 2020 12:56:17 +0000
Subject: [PATCH] Fix GCC build failure in WasmBaselineCompile.cpp
GCC does not yet implement C++ Core DR 727, so explicit specializations
at class scope aren't allowed. This replaces it with a different C++17
feature: using if-constexpr inside the function body and checking the
template argument there.
See https://bugzilla.mozilla.org/show_bug.cgi?id=1677690
and https://bugzilla.redhat.com/show_bug.cgi?id=1897675
---
js/src/wasm/WasmBaselineCompile.cpp | 24 ++++++++++--------------
1 file changed, 10 insertions(+), 14 deletions(-)
diff --git a/js/src/wasm/WasmBaselineCompile.cpp b/js/src/wasm/WasmBaselineCompile.cpp
index 676dbfa73d33a..b82aa242d3c6b 100644
--- js/src/wasm/WasmBaselineCompile.cpp
+++ js/src/wasm/WasmBaselineCompile.cpp
@@ -655,15 +655,13 @@ class BaseRegAlloc {
template <MIRType t>
bool hasFPU() {
- return availFPU.hasAny<RegTypeOf<t>::value>();
- }
-
#ifdef RABALDR_SIDEALLOC_V128
- template <>
- bool hasFPU<MIRType::Simd128>() {
- MOZ_CRASH("Should not happen");
- }
+ if constexpr (t == MIRType::Simd128)
+ MOZ_CRASH("Should not happen");
+ else
#endif
+ return availFPU.hasAny<RegTypeOf<t>::value>();
+ }
bool isAvailableGPR(Register r) { return availGPR.has(r); }
@@ -746,15 +744,13 @@ class BaseRegAlloc {
template <MIRType t>
FloatRegister allocFPU() {
- return availFPU.takeAny<RegTypeOf<t>::value>();
- }
-
#ifdef RABALDR_SIDEALLOC_V128
- template <>
- FloatRegister allocFPU<MIRType::Simd128>() {
- MOZ_CRASH("Should not happen");
- }
+ if constexpr (t == MIRType::Simd128)
+ MOZ_CRASH("Should not happen");
+ else
#endif
+ return availFPU.takeAny<RegTypeOf<t>::value>();
+ }
void freeGPR(Register r) { availGPR.add(r); }

View file

@ -3,15 +3,15 @@
# THIS PKG MUST BE SYNCHRONIZED WITH "srcpkgs/firefox-i18n".
#
pkgname=firefox
version=83.0
revision=2
version=84.0
revision=1
build_helper="rust"
short_desc="Mozilla Firefox web browser"
maintainer="Johannes <johannes.brechtmann@gmail.com>"
license="MPL-2.0, GPL-2.0-or-later, LGPL-2.1-or-later"
homepage="https://www.mozilla.org/firefox/"
distfiles="${MOZILLA_SITE}/${pkgname}/releases/${version}/source/${pkgname}-${version}.source.tar.xz"
checksum=d69e84e8b8449f828683d274c24e03095858362bfed21b08bdd7fe715eea5398
checksum=23273ef0165b243f5d0908c38e7854d38070282c9b526e8d93b7503cd5f69138
lib32disabled=yes
@ -133,7 +133,7 @@ do_build() {
export CXXFLAGS="${CXXFLAGS/-g/-g1}"
export LDFLAGS+=" -Wl,--no-keep-memory"
# patch the rust debug level, this is hardcoded
sed -i "s/debug_info = '2'/debug_info = '1'/" \
sed -i 's/debug_info = "2"/debug_info = "1"/' \
build/moz.configure/toolchain.configure
fi