diff options
| author | J0WI <J0WI@users.noreply.github.com> | 2019-10-26 17:04:12 +0200 |
|---|---|---|
| committer | Rasmus Thomsen <oss@cogitri.dev> | 2019-10-26 23:11:17 +0200 |
| commit | 7e130731a332e3d5d593b52869e2f4e02da33f59 (patch) | |
| tree | 5078b4359f3939c406c071405faea8bedc516154 /testing | |
| parent | 00be3a44472d6239a5052218d41d055fba9b3634 (diff) | |
| download | aports-7e130731a332e3d5d593b52869e2f4e02da33f59.tar.bz2 aports-7e130731a332e3d5d593b52869e2f4e02da33f59.tar.xz | |
testing/thunderbird: upgrade to 68.2.0
Diffstat (limited to 'testing')
19 files changed, 133 insertions, 406 deletions
diff --git a/testing/thunderbird/0002-Use-C99-math-isfinite.patch b/testing/thunderbird/0002-Use-C99-math-isfinite.patch deleted file mode 100644 index ba4f5cfb3d..0000000000 --- a/testing/thunderbird/0002-Use-C99-math-isfinite.patch +++ /dev/null @@ -1,17 +0,0 @@ ---- ./xpcom/ds/nsMathUtils.h.orig -+++ ./xpcom/ds/nsMathUtils.h -@@ -104,12 +104,12 @@ - #ifdef WIN32 - // NOTE: '!!' casts an int to bool without spamming MSVC warning C4800. - return !!_finite(aNum); --#elif defined(XP_DARWIN) -+#elif defined(XP_DARWIN) || defined(_GLIBCXX_CMATH) - // Darwin has deprecated |finite| and recommends |isfinite|. The former is - // not present in the iOS SDK. - return std::isfinite(aNum); - #else -- return finite(aNum); -+ return isfinite(aNum); - #endif - } - diff --git a/testing/thunderbird/APKBUILD b/testing/thunderbird/APKBUILD index 191fcf8c8b..a610b5e845 100644 --- a/testing/thunderbird/APKBUILD +++ b/testing/thunderbird/APKBUILD @@ -2,13 +2,13 @@ # Maintainer: Joseph Benden <joe@benden.us> pkgname=thunderbird -pkgver=60.9.0 +pkgver=68.2.0 _pkgver=$pkgver _xulver=$pkgver pkgrel=0 pkgdesc="Thunderbird email client" url="https://www.thunderbird.net/" -arch="x86_64" +arch="x86_64 aarch64" # limited by rust and cargo license="GPL-3.0-or-later AND LGPL-2.1-or-later AND MPL-2.0" options="!check !strip" depends=" @@ -56,17 +56,16 @@ makedepends=" libtheora-dev libtool libvorbis-dev - libvpx-dev libxcomposite-dev libxt-dev - llvm-dev + llvm9-dev mesa-dev nasm nodejs nspr-dev nss-dev nss-static - paxmark + python2 python3-dev sed sqlite-dev @@ -77,38 +76,23 @@ makedepends=" " source="https://ftp.mozilla.org/pub/thunderbird/releases/$pkgver/source/thunderbird-$pkgver.source.tar.xz stab.h + + disable-ccache-stats.patch fix-fortify-system-wrappers.patch - fix-fortify-inline.patch fix-seccomp-bpf.patch fix-toolkit.patch fix-tools.patch mallinfo.patch - mozilla-build-arm.patch + disable-moz-stackwalk.patch + fix-musl.patch fix-rust-target.patch - fix-bug-1261392.patch fix-webrtc-glibcisms.patch - sandbox-membarrier.patch - rust-unitialized-field.patch - rust133.patch - 0003-Disable-ccache-stats.patch - rust-cssparser.patch + fix-sandbox-membarrier.patch thunderbird.desktop " _mozappdir=/usr/lib/$pkgname -# Google API keys (see http://www.chromium.org/developers/how-tos/api-keys) -# Note: These are for Arch Linux use ONLY. For your own distribution, please -# get your own set of keys. Feel free to contact foutrelis@archlinux.org for -# more information. -_google_api_key=AIzaSyDwr302FpOSkGRpLlUpPThNTDPbXcIn_FM - -# Mozilla API keys (see https://location.services.mozilla.com/api) -# Note: These are for Arch Linux use ONLY. For your own distribution, please -# get your own set of keys. Feel free to contact heftig@archlinux.org for -# more information. -_mozilla_api_key=16674381-f021-49de-8622-3021c5942aff - # help our shared-object scanner to find the libs ldpath="$_mozappdir" sonameprefix="$pkgname:" @@ -129,14 +113,11 @@ prepare() { mkdir -p "$builddir"/objdir echo "ac_add_options BINDGEN_CFLAGS='-I/usr/include/nspr -I/usr/include/pixman-1'" >>objdir/.mozconfig - # add API keys - echo -n "${_google_api_key}" > $builddir/objdir/google-api-key - echo -n "${_mozilla_api_key}" > $builddir/objdir/mozilla-api-key - _clear_vendor_checksums cssparser } build() { + mkdir -p "$builddir"/objdir cd "$builddir"/objdir sed -e 's/checkImpl/checkFFImpl/g' -i ../js/src/vm/JSContext*.h @@ -158,18 +139,29 @@ build() { export CXXFLAGS="$CXXFLAGS -Wno-class-memaccess -Wno-multistatement-macros -Wno-ignored-qualifiers" export LDFLAGS="$LDFLAGS -Wno-subobject-linkage" - ../mach configure \ + case "$CARCH" in + x86_64) + # disable-elf-hack: exists only on arm, x86, x86_64 + _arch_config="--disable-elf-hack" + export RUST_TARGET="$CTARGET" + ;; + aarch64) + export RUST_TARGET="aarch64-unknown-linux-musl" + ;; + esac + + ../configure \ --prefix=/usr \ --libdir=/usr/lib \ + $_arch_config \ \ --disable-crashreporter \ - --disable-elf-hack \ --disable-gold \ - --enable-install-strip \ + --disable-install-strip \ --disable-jemalloc \ --disable-profiling \ --disable-pulseaudio \ - --enable-strip \ + --disable-strip \ --disable-tests \ --disable-updater \ --disable-debug \ @@ -180,22 +172,17 @@ build() { --enable-application=comm/mail \ --enable-default-toolkit=cairo-gtk3 \ --enable-official-branding \ - --enable-optimize="$CFLAGS -fno-ident -fmerge-all-constants -ffunction-sections -fdata-sections -Wno-maybe-uninitialized -Wno-implicit-fallthrough -Wno-unused-function" \ + --enable-optimize="$CFLAGS -O2 -fno-ident -fmerge-all-constants -ffunction-sections -fdata-sections -Wno-maybe-uninitialized -Wno-implicit-fallthrough -Wno-unused-function" \ --enable-release \ --enable-startup-notification \ --enable-system-ffi \ --enable-system-sqlite \ --enable-ffmpeg \ --enable-hardening \ - \ - --with-google-location-service-api-keyfile="${builddir}/objdir/google-api-key" \ - --with-google-safebrowsing-api-keyfile="${builddir}/objdir/google-api-key" \ - --with-mozilla-api-keyfile="${builddir}/objdir/mozilla-api-key" \ + --enable-rust-simd \ \ --with-system-bz2 \ - --with-system-hunspell \ --with-system-icu \ - --with-system-jpeg \ --with-system-libevent \ --with-system-nspr \ --with-system-nss \ @@ -205,9 +192,9 @@ build() { --without-ccache \ --with-clang-path=/usr/bin/clang \ --with-libclang-path=/usr/lib - #--with-system-libvpx # requires 1.7x to work, we've got 1.8.0 currently - - ../mach build -v + # FIXME: fix build with --with-system-libvpx and libvpx 1.8.0 + # https://bugzilla.mozilla.org/show_bug.cgi?id=1525393 + make } package() { @@ -233,14 +220,6 @@ package() { install -m644 ${srcdir}/$pkgname.desktop ${pkgdir}/usr/share/applications/$pkgname.desktop - # thunderbird currently does not work with mprotect. disable it for now - local paxflags="-mp" - [ "$CARCH" = "x86" ] && paxflags="-msp" - - paxmark "$paxflags" "$pkgdir"/$_mozappdir/thunderbird-bin - paxmark "$paxflags" "$pkgdir"/$_mozappdir/plugin-container - paxmark "$paxflags" "$pkgdir"/$_mozappdir/pingsender - _vendorjs="$pkgdir/usr/lib/$pkgname/defaults/preferences/vendor.js" install -Dm644 /dev/stdin "$_vendorjs" <<END // Use LANG environment variable to choose locale @@ -270,11 +249,6 @@ app.distributor.channel=$pkgname app.partner.alpinelinux=alpinelinux END - # Use system-provided dictionaries - rm -r "$pkgdir/usr/lib/$pkgname/dictionaries" - ln -Ts /usr/share/hunspell "$pkgdir/usr/lib/$pkgname/dictionaries" - ln -Ts /usr/share/hyphen "$pkgdir/usr/lib/$pkgname/hyphenation" - # Install a wrapper to avoid confusion about binary path install -Dm755 /dev/stdin "$pkgdir/usr/bin/$pkgname" <<END #!/bin/sh @@ -287,22 +261,17 @@ END "$pkgdir/usr/lib/$pkgname/thunderbird-bin" } -sha512sums="f59d48fba7fb8a4bf7cb160e6ca2508312a7fce950c12f133206935bcdb4c9844a9cb063aa3aae67c82562d2a51e123cc1f5bbad0238a1e5ce386c514295bdd1 thunderbird-60.9.0.source.tar.xz +sha512sums="ca9afc870245dfaaabe3c75d4db266596c9dd714ea20b775b80e5d9df4671a5c71d2af84c734e27e07efcdb6f0fac0c34b48fda45a5a64e3e092bdafea474efc thunderbird-68.2.0.source.tar.xz 0b3f1e4b9fdc868e4738b5c81fd6c6128ce8885b260affcb9a65ff9d164d7232626ce1291aaea70132b3e3124f5e13fef4d39326b8e7173e362a823722a85127 stab.h +3e57b2541f3889a1cf701860c8bf299f294cb077b0e8cfffda271cf02d1f59b25a697485d0df66e847e47f795b1ace54488a84a42851f2f8587717335537b44d disable-ccache-stats.patch 2f4f15974d52de4bb273b62a332d13620945d284bbc6fe6bd0a1f58ff7388443bc1d3bf9c82cc31a8527aad92b0cd3a1bc41d0af5e1800e0dcbd7033e58ffd71 fix-fortify-system-wrappers.patch -09bc32cf9ee81b9cc6bb58ddbc66e6cc5c344badff8de3435cde5848e5a451e0172153231db85c2385ff05b5d9c20760cb18e4138dfc99060a9e960de2befbd5 fix-fortify-inline.patch -183a4ef62cd79728117797235fe46ecd3e4336c008d615c2b2a64c707477e403aed1ee5e19feb86611b93ebecc00df339aa28a73735e045e38f0d1ce3080341b fix-seccomp-bpf.patch -2f1bf85a340a82800dd6ba406c23489c319ec037b404f4240837854e2520b9ff11fcca0d51ac05b451c474e800fd8be13b1c57ae2917e9d1c7e5b6d91cf7e2d2 fix-toolkit.patch -48683964624bb58b5a2a2a5c89da56e3b8dcd04f8d42c6910bea5365010a77d6d82bdd48259774ca54341edc05b6768eaa6aa1b453718c02f760361197e78b52 fix-tools.patch -69e628668a2f450da249f761e375600e03674aeb6268dac9e282b1a7008ba47292cc8470cbc04a0ccc1d836d1653c56bb1495d5a127f906adf5807f7f95438c1 mallinfo.patch -3671bf7623c1825c977668efec62b57873bc6052becfd8a68ddcbc2d0ba96e0c3966c61b24716e6c48167d44280d3e690a4ff986907ceba5811a653e87770fff mozilla-build-arm.patch -e62be6e08c7e0a1d2486f271426d3986a0870f2118442ccb424a509dfc5f92cc17d05cd7e46336176afb7bd9f495b29bb739c8f88ccf918de86209efe00caf95 disable-moz-stackwalk.patch -42cc44fda4b05259b38f055d6f51461746aa89a474cedc5e92fb9d20879da0d12b1b515b273a549e7302cda9c7eddde20d5fdba09853e5c658784ad6d0b20078 fix-rust-target.patch -fdd698ddd94d4265cc82aa063fce1522908ad4f5f118fd207e0d64a0409e1e04e3f096625caacbacb251b42cafe0d743bb0a0b9463a882d8938b5bb4562a05e1 fix-bug-1261392.patch -d09401eaa9620c9d4fa368865539fc4efb66eafb362d2195a653a6c6fd65e9370ced1b1b005993cbd181011360327dcb38e4b3e77b711f2c5ccf22d235ed4ef6 fix-webrtc-glibcisms.patch -e725a6e9b2361cd566ae2f90861dbce9f2231f16721ec02f4b9f9986b7dc82cc006ea6a500ae7f30c095ce746132a5bd1d9532c4cf0d1541dcc672a20aef8807 sandbox-membarrier.patch -01b48a708cc6bc6e3cd7cc7b16f5137ec344566ac891d699b65e322bc992726072fa14a54cef1a7775799fcbbcf90a6c170107c8524caba3bc311b42d93b7581 rust-unitialized-field.patch -66a847c2889acc794f4db5c47f8a30e819c120f84457d5c2e094e4a2ba990036e6ca84af9d799d7446b058a5fd7292926c6e4996f105d494f1b6e8e5f3b9a6a5 rust133.patch -3e57b2541f3889a1cf701860c8bf299f294cb077b0e8cfffda271cf02d1f59b25a697485d0df66e847e47f795b1ace54488a84a42851f2f8587717335537b44d 0003-Disable-ccache-stats.patch -cbc7fdf297647e15ddbec87d6ac6392bb8d395a9a30d035a49d8779945f7dadbf8eb245f4220b01acbc6b3bd4e815a2eae77a2f83f2114785677fa432d2b2520 rust-cssparser.patch +84b84d2d7dbc16002510bf856796ad345ac38ef6d3254670230189bba7c2d4781714d231236d5a3d70129a4597b430c3171644b01ad0f5a5bb13b55d407337a4 fix-seccomp-bpf.patch +2c65ea7280e6e89826ebad563ee25203a99ff0b4ba8fc60ec261ada6c69874d649c6ac92fcecc6307a6e5a00de27d7956acf944d556ddfadec0411be16f4e0b8 fix-toolkit.patch +4d55f41d15be7457ad630f8f07e4fc0314c2f75720010b4bbe6a2a7f3228210a1e069949e11795efbe2e784b0762e79fdfe5b8ec38e8a64cb8d9cf3b57dd5af1 fix-tools.patch +a4a3e062661bda64d502d426c480ac9645345860118de9df9ffe6e0597738c70c11e5cdef2d4fd12c5e2ee30a09310159230524655a419a4f7e4eeeb0f3c06b0 mallinfo.patch +454ea3263cabce099accbdc47aaf83be26a19f8b5a4568c01a7ef0384601cf8315efd86cd917f9c8bf419c2c845db89a905f3ff9a8eb0c8e41042e93aa96a85c disable-moz-stackwalk.patch +e0df4fc649012f023443ce9165da29d36459dbca5df64a31008b28d96264fba909858de36d0cf1b1cb1aab898342413f0cd77c90ebe21d1f9a0504631d6d1d0e fix-musl.patch +7903987b4b661286de03c6940bf67aaed6d78c9adc57680413407a84a1f1f26aaded35e6d53ea6ad527b474968b343d844e81e16d777c0e29b830b51aa2ca8c3 fix-rust-target.patch +d35cacb9ede80e6bfbef0709823e536dddfb1c02d776275b0b7adb5969e9927d8c6117df96873569c3f3db0a18ee5db24f8086a9311a05077892be43a3dd8d79 fix-webrtc-glibcisms.patch +f85f2c19c3dafab915bcb40e580fc442fd9eab5916696849edf0b105c758dd807dfe23a6479935613c81496711eb377c73227c03eb8582204c3442a4d0e397a2 fix-sandbox-membarrier.patch 95a2b1deb4f6c90750fdd2bfe8ca0a7879a5b267965091705a6beb0a0a4b1ccad75d11df7b9885543ca4232ff704e975c6946f4c11804cb71c471e06f9576001 thunderbird.desktop" diff --git a/testing/thunderbird/0003-Disable-ccache-stats.patch b/testing/thunderbird/disable-ccache-stats.patch index 82ca2aa1cb..82ca2aa1cb 100644 --- a/testing/thunderbird/0003-Disable-ccache-stats.patch +++ b/testing/thunderbird/disable-ccache-stats.patch diff --git a/testing/thunderbird/disable-moz-stackwalk.patch b/testing/thunderbird/disable-moz-stackwalk.patch index 214ab69e73..b6bc756d2b 100644 --- a/testing/thunderbird/disable-moz-stackwalk.patch +++ b/testing/thunderbird/disable-moz-stackwalk.patch @@ -1,16 +1,18 @@ +diff --git a/mozglue/misc/StackWalk.cpp b/mozglue/misc/StackWalk.cpp +index 7d62921..adcfa44 100644 --- a/mozglue/misc/StackWalk.cpp +++ b/mozglue/misc/StackWalk.cpp -@@ -32,13 +32,7 @@ - #define MOZ_STACKWALK_SUPPORTS_MACOSX 0 +@@ -33,13 +33,7 @@ using namespace mozilla; + # define MOZ_STACKWALK_SUPPORTS_MACOSX 0 #endif -#if (defined(linux) && \ - ((defined(__GNUC__) && (defined(__i386) || defined(PPC))) || \ - defined(HAVE__UNWIND_BACKTRACE))) --#define MOZ_STACKWALK_SUPPORTS_LINUX 1 +-# define MOZ_STACKWALK_SUPPORTS_LINUX 1 -#else - #define MOZ_STACKWALK_SUPPORTS_LINUX 0 + # define MOZ_STACKWALK_SUPPORTS_LINUX 0 -#endif #if __GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) - #define HAVE___LIBC_STACK_END 1 + # define HAVE___LIBC_STACK_END 1 diff --git a/testing/thunderbird/fix-bug-1261392.patch b/testing/thunderbird/fix-bug-1261392.patch deleted file mode 100644 index acf56e1ece..0000000000 --- a/testing/thunderbird/fix-bug-1261392.patch +++ /dev/null @@ -1,27 +0,0 @@ -diff --git a/tools/profiler/core/platform.h b/tools/profiler/core/platform.h -index 5f0fb69..086a511 100644 ---- a/tools/profiler/core/platform.h -+++ b/tools/profiler/core/platform.h -@@ -42,10 +42,11 @@ - #include "PlatformMacros.h" - #include <vector> - --// We need a definition of gettid(), but glibc doesn't provide a --// wrapper for it. --#if defined(__GLIBC__) -+// We need a definition of gettid(), but Linux libc implementations don't -+// provide a wrapper for it (except for Bionic) -+#if defined(__linux__) - #include <unistd.h> -+#if !defined(__BIONIC__) - #include <sys/syscall.h> - static inline pid_t gettid() { return (pid_t)syscall(SYS_gettid); } - #elif defined(GP_OS_darwin) -@@ -61,6 +62,7 @@ static inline pid_t gettid() { return (pid_t)syscall(SYS_thread_selfid); } - #define getpid _getpid - #endif - #endif -+#endif - - extern mozilla::LazyLogModule gProfilerLog; - diff --git a/testing/thunderbird/fix-fortify-inline.patch b/testing/thunderbird/fix-fortify-inline.patch deleted file mode 100644 index 2498c57fc7..0000000000 --- a/testing/thunderbird/fix-fortify-inline.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/media/webrtc/signaling/src/sdp/sipcc/sdp_os_defs.h -+++ b/media/webrtc/signaling/src/sdp/sipcc/sdp_os_defs.h -@@ -27,8 +27,5 @@ - typedef int16_t int16; - typedef unsigned short ushort; - typedef unsigned long ulong; --#ifndef __GNUC_STDC_INLINE__ --#define inline --#endif - - #endif /* _SDP_OS_DEFS_H_ */ diff --git a/testing/thunderbird/fix-musl.patch b/testing/thunderbird/fix-musl.patch new file mode 100644 index 0000000000..996a45f130 --- /dev/null +++ b/testing/thunderbird/fix-musl.patch @@ -0,0 +1,11 @@ +--- a/tools/profiler/core/platform-linux-android.cpp 2019-07-09 22:58:30.039475686 +0200 ++++ b/tools/profiler/core/platform-linux-android.cpp 2019-07-09 22:58:39.331437677 +0200 +@@ -73,7 +73,7 @@ + + int profiler_current_thread_id() { + // glibc doesn't provide a wrapper for gettid(). +-#if defined(__GLIBC__) ++#if defined(__linux__) + return static_cast<int>(static_cast<pid_t>(syscall(SYS_gettid))); + #else + return static_cast<int>(gettid()); diff --git a/testing/thunderbird/fix-rust-target.patch b/testing/thunderbird/fix-rust-target.patch index 7dd760ca1d..f81418efd2 100644 --- a/testing/thunderbird/fix-rust-target.patch +++ b/testing/thunderbird/fix-rust-target.patch @@ -1,10 +1,12 @@ --- a/build/moz.configure/rust.configure +++ b/build/moz.configure/rust.configure -@@ -181,9 +181,11 @@ +@@ -280,9 +280,13 @@ die("Don't know how to translate {} for rustc".format( host_or_target.alias)) -+ fixed_alias = rustc_target.alias.replace("-unknown-", "-alpine-").replace("-gnu", "-musl") ++ fixed_alias = rustc_target.alias.replace("-gnu", "-musl") ++ if host_or_target.cpu != 'aarch64': ++ fixed_alias = fixed_alias.replace("-unknown-", "-alpine-") + # Check to see whether our rustc has a reasonably functional stdlib # for our chosen target. @@ -13,7 +15,7 @@ in_fd, in_path = mkstemp(prefix='conftest', suffix='.rs') out_fd, out_path = mkstemp(prefix='conftest', suffix='.rlib') os.close(out_fd) -@@ -220,7 +222,7 @@ +@@ -319,7 +323,7 @@ os.remove(out_path) # This target is usable. diff --git a/testing/thunderbird/sandbox-membarrier.patch b/testing/thunderbird/fix-sandbox-membarrier.patch index 24b70ca401..4bd3b80d2a 100644 --- a/testing/thunderbird/sandbox-membarrier.patch +++ b/testing/thunderbird/fix-sandbox-membarrier.patch @@ -4,7 +4,7 @@ Taken from voidlinux: https://github.com/void-linux/void-packages/commit/4198411 --- a/security/sandbox/linux/SandboxFilter.cpp +++ b/security/sandbox/linux/SandboxFilter.cpp -@@ -283,6 +283,8 @@ +@@ -572,6 +572,8 @@ case __NR_set_tid_address: return Allow(); #endif diff --git a/testing/thunderbird/fix-seccomp-bpf.patch b/testing/thunderbird/fix-seccomp-bpf.patch index ae3ba5d44b..de7bd175ee 100644 --- a/testing/thunderbird/fix-seccomp-bpf.patch +++ b/testing/thunderbird/fix-seccomp-bpf.patch @@ -1,6 +1,5 @@ -diff -ru firefox-62.0.3.orig/security/sandbox/chromium/sandbox/linux/seccomp-bpf/trap.cc firefox-62.0.3/security/sandbox/chromium/sandbox/linux/seccomp-bpf/trap.cc ---- firefox-62.0.3.orig/security/sandbox/chromium/sandbox/linux/seccomp-bpf/trap.cc 2018-12-14 08:53:46.083976137 +0000 -+++ firefox-62.0.3/security/sandbox/chromium/sandbox/linux/seccomp-bpf/trap.cc 2018-12-14 08:51:22.084596411 +0000 +--- a/security/sandbox/chromium/sandbox/linux/seccomp-bpf/trap.cc 2018-12-14 08:53:46.083976137 +0000 ++++ b/security/sandbox/chromium/sandbox/linux/seccomp-bpf/trap.cc 2018-12-14 08:51:22.084596411 +0000 @@ -25,6 +25,11 @@ #include "sandbox/linux/system_headers/linux_seccomp.h" #include "sandbox/linux/system_headers/linux_signal.h" @@ -13,14 +12,3 @@ diff -ru firefox-62.0.3.orig/security/sandbox/chromium/sandbox/linux/seccomp-bpf namespace { struct arch_sigsys { -diff -ru firefox-62.0.3.orig/security/sandbox/linux/SandboxFilter.cpp firefox-62.0.3/security/sandbox/linux/SandboxFilter.cpp ---- firefox-62.0.3.orig/security/sandbox/linux/SandboxFilter.cpp 2018-10-01 18:35:28.000000000 +0000 -+++ firefox-62.0.3/security/sandbox/linux/SandboxFilter.cpp 2018-12-14 08:57:50.645264590 +0000 -@@ -997,6 +997,7 @@ class ContentSandboxPolicy : public SandboxPolicyCommon { - // ffmpeg, and anything else that calls isatty(), will be told - // that nothing is a typewriter: - .ElseIf(request == TCGETS, Error(ENOTTY)) -+ .ElseIf(request == TIOCGWINSZ, Error(ENOTTY)) - // Allow anything that isn't a tty ioctl, for now; bug 1302711 - // will cover changing this to a default-deny policy. - .ElseIf(shifted_type != kTtyIoctls, Allow()) diff --git a/testing/thunderbird/fix-stack-overflow.patch b/testing/thunderbird/fix-stack-overflow.patch deleted file mode 100644 index e164fc69b6..0000000000 --- a/testing/thunderbird/fix-stack-overflow.patch +++ /dev/null @@ -1,45 +0,0 @@ -https://bugs.alpinelinux.org/issues/5559 -https://bugzilla.mozilla.org/show_bug.cgi?id=1274732 - -diff --git a/netwerk/streamconv/converters/nsHTTPCompressConv.cpp b/netwerk/streamconv/converters/nsHTTPCompressConv.cpp -index 1193529..aeb96b5 100644 ---- a/netwerk/streamconv/converters/nsHTTPCompressConv.cpp -+++ b/netwerk/streamconv/converters/nsHTTPCompressConv.cpp -@@ -165,9 +165,8 @@ nsHTTPCompressConv::BrotliHandler(nsIInputStream *stream, void *closure, const c - nsHTTPCompressConv *self = static_cast<nsHTTPCompressConv *>(closure); - *countRead = 0; - -- const uint32_t kOutSize = 128 * 1024; // just a chunk size, we call in a loop -- unsigned char outBuffer[kOutSize]; -- unsigned char *outPtr; -+ const size_t kOutSize = 128 * 1024; // just a chunk size, we call in a loop -+ uint8_t *outPtr; - size_t outSize; - size_t avail = aAvail; - BrotliResult res; -@@ -177,9 +176,15 @@ nsHTTPCompressConv::BrotliHandler(nsIInputStream *stream, void *closure, const c - return NS_OK; - } - -+ auto outBuffer = MakeUniqueFallible<uint8_t[]>(kOutSize); -+ if (outBuffer == nullptr) { -+ self->mBrotli->mStatus = NS_ERROR_OUT_OF_MEMORY; -+ return self->mBrotli->mStatus; -+ } -+ - do { - outSize = kOutSize; -- outPtr = outBuffer; -+ outPtr = outBuffer.get(); - - // brotli api is documented in brotli/dec/decode.h and brotli/dec/decode.c - LOG(("nsHttpCompresssConv %p brotlihandler decompress %d\n", self, avail)); -@@ -210,7 +215,7 @@ nsHTTPCompressConv::BrotliHandler(nsIInputStream *stream, void *closure, const c - nsresult rv = self->do_OnDataAvailable(self->mBrotli->mRequest, - self->mBrotli->mContext, - self->mBrotli->mSourceOffset, -- reinterpret_cast<const char *>(outBuffer), -+ reinterpret_cast<const char *>(outBuffer.get()), - outSize); - LOG(("nsHttpCompressConv %p BrotliHandler ODA rv=%x", self, rv)); - if (NS_FAILED(rv)) { diff --git a/testing/thunderbird/fix-toolkit.patch b/testing/thunderbird/fix-toolkit.patch index 8c7ebc1c86..414734dfec 100644 --- a/testing/thunderbird/fix-toolkit.patch +++ b/testing/thunderbird/fix-toolkit.patch @@ -2,7 +2,7 @@ diff --git a/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols index 4222ce3..4d40c6a 100644 --- a/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc +++ b/toolkit/crashreporter/google-breakpad/src/common/linux/dump_symbols.cc -@@ -45,6 +45,7 @@ +@@ -46,6 +46,7 @@ #include <sys/mman.h> #include <sys/stat.h> #include <unistd.h> @@ -42,7 +42,7 @@ diff --git a/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_sys index 93fdad7..f34e5e0 100644 --- a/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h +++ b/toolkit/crashreporter/google-breakpad/src/third_party/lss/linux_syscall_support.h -@@ -1134,6 +1134,12 @@ struct kernel_statfs { +@@ -1239,6 +1239,12 @@ struct kernel_statfs { #ifndef __NR_fallocate #define __NR_fallocate 285 #endif @@ -59,28 +59,28 @@ diff --git a/toolkit/mozapps/update/common/updatedefines.h b/toolkit/mozapps/upd index 79276f7..4c67976 100644 --- a/toolkit/mozapps/update/common/updatedefines.h +++ b/toolkit/mozapps/update/common/updatedefines.h -@@ -100,7 +100,7 @@ static inline int mywcsprintf(WCHAR* dest, size_t count, const WCHAR* fmt, +@@ -87,7 +87,7 @@ static inline int mywcsprintf(WCHAR* dest, size_t count, const WCHAR* fmt, - #ifdef SOLARIS - #include <sys/stat.h> --#else -+#elif !defined(__linux__) || defined(__GLIBC__) - #include <fts.h> - #endif - #include <dirent.h> + # ifdef SOLARIS + # include <sys/stat.h> +-# else ++# elif !defined(__linux__) || defined(__GLIBC__) + # include <fts.h> + # endif + # include <dirent.h> diff --git a/toolkit/mozapps/update/updater/updater.cpp b/toolkit/mozapps/update/updater/updater.cpp index 257ccb4..01314e4 100644 --- a/toolkit/mozapps/update/updater/updater.cpp +++ b/toolkit/mozapps/update/updater/updater.cpp -@@ -3737,6 +3737,7 @@ int add_dir_entries(const NS_tchar *dirpath, ActionList *list) - int add_dir_entries(const NS_tchar *dirpath, ActionList *list) - { +@@ -3978,6 +3978,7 @@ + + int add_dir_entries(const NS_tchar* dirpath, ActionList* list) { int rv = OK; +#if !defined(__linux__) || defined(__GLIBC__) - FTS *ftsdir; - FTSENT *ftsdirEntry; - NS_tchar searchpath[MAXPATHLEN]; -@@ -3840,6 +3841,7 @@ int add_dir_entries(const NS_tchar *dirpath, ActionList *list) + FTS* ftsdir; + FTSENT* ftsdirEntry; + mozilla::UniquePtr<NS_tchar[]> searchpath(get_full_path(dirpath)); +@@ -4085,6 +4086,7 @@ } fts_close(ftsdir); diff --git a/testing/thunderbird/fix-tools.patch b/testing/thunderbird/fix-tools.patch index edecb7f678..93b9d19c84 100644 --- a/testing/thunderbird/fix-tools.patch +++ b/testing/thunderbird/fix-tools.patch @@ -1,14 +1,23 @@ ---- a/tools/profiler/core/platform.h -+++ b/tools/profiler/core/platform.h -@@ -29,6 +29,8 @@ - #ifndef TOOLS_PLATFORM_H_ - #define TOOLS_PLATFORM_H_ - -+#include <sys/types.h> -+ - #include <stdint.h> - #include <math.h> - #include "MainThreadUtils.h" +diff --git a/tools/profiler/core/platform-linux-android.cpp b/tools/profiler/core/platform-linux-android.cpp +index 19d0a5c56d..b64b543066 100644 +--- a/tools/profiler/core/platform-linux-android.cpp ++++ b/tools/profiler/core/platform-linux-android.cpp +@@ -506,8 +506,10 @@ static void PlatformInit(PSLockRef aLock) {} + ucontext_t sSyncUContext; + + void Registers::SyncPopulate() { +- if (!getcontext(&sSyncUContext)) { +- PopulateRegsFromContext(*this, &sSyncUContext); +- } ++ #if defined(__GLIBC__) ++ if (!getcontext(&sSyncUContext)) { ++ PopulateRegsFromContext(*this, &sSyncUContext); ++ } ++ #endif + } + #endif +diff --git a/tools/profiler/lul/LulElf.cpp b/tools/profiler/lul/LulElf.cpp +index 9998d04d0d..348a7086fc 100644 --- a/tools/profiler/lul/LulElf.cpp +++ b/tools/profiler/lul/LulElf.cpp @@ -469,10 +469,10 @@ string FormatIdentifier(unsigned char identifier[16]) { @@ -25,21 +34,4 @@ + string base = p ? p+1 : c_filename; return base; } - ---- a/tools/profiler/core/platform-linux-android.cpp -+++ b/tools/profiler/core/platform-linux-android.cpp -@@ -497,8 +497,10 @@ static void PlatformInit(PSLockRef aLock) {} - ucontext_t sSyncUContext; - - void Registers::SyncPopulate() { -- if (!getcontext(&sSyncUContext)) { -- PopulateRegsFromContext(*this, &sSyncUContext); -- } -+ #if defined(__GLIBC__) -+ if (!getcontext(&sSyncUContext)) { -+ PopulateRegsFromContext(*this, &sSyncUContext); -+ } -+ #endif - } - #endif diff --git a/testing/thunderbird/fix-webrtc-glibcisms.patch b/testing/thunderbird/fix-webrtc-glibcisms.patch index 958f9ef6c1..658b076dc8 100644 --- a/testing/thunderbird/fix-webrtc-glibcisms.patch +++ b/testing/thunderbird/fix-webrtc-glibcisms.patch @@ -1,13 +1,20 @@ ---- a/media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c 2018-05-09 23:48:44.677389171 +0200 -+++ b/media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c 2018-05-09 23:48:56.254373557 +0200 -@@ -11,7 +11,9 @@ - #include <stdlib.h> - #include <string.h> - #include <features.h> +--- ./media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c.orig 2018-05-09 23:48:44.677389171 +0200 ++++ ./media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c 2018-05-09 23:48:56.254373557 +0200 +@@ -14,7 +14,7 @@ + #ifndef __GLIBC_PREREQ + #define __GLIBC_PREREQ(a, b) 0 + #endif -#if __GLIBC_PREREQ(2, 16) -+#if !__GLIBC__ -+#include <sys/auxv.h> -+#elif __GLIBC_PREREQ(2, 16) ++#if !__GLIBC__ || __GLIBC_PREREQ(2, 16) #include <sys/auxv.h> #else #include <fcntl.h> +@@ -32,7 +32,7 @@ + int architecture = 0; + unsigned long hwcap = 0; + const char* platform = NULL; +-#if __GLIBC_PREREQ(2, 16) ++#if !__GLIBC__ || __GLIBC_PREREQ(2, 16) + hwcap = getauxval(AT_HWCAP); + platform = (const char*)getauxval(AT_PLATFORM); + #else diff --git a/testing/thunderbird/mallinfo.patch b/testing/thunderbird/mallinfo.patch index 91c65dd059..7916a200ca 100644 --- a/testing/thunderbird/mallinfo.patch +++ b/testing/thunderbird/mallinfo.patch @@ -1,18 +1,20 @@ +diff --git a/xpcom/base/nsMemoryReporterManager.cpp b/xpcom/base/nsMemoryReporterManager.cpp +index 865e1b5430..9a00dafecb 100644 --- a/xpcom/base/nsMemoryReporterManager.cpp +++ b/xpcom/base/nsMemoryReporterManager.cpp -@@ -153,6 +153,7 @@ ResidentUniqueDistinguishedAmount(int64_t* aN) +@@ -124,6 +124,7 @@ static MOZ_MUST_USE nsresult ResidentUniqueDistinguishedAmount(int64_t* aN) { return GetProcSelfSmapsPrivate(aN); } - + +#ifdef __GLIBC__ - #define HAVE_SYSTEM_HEAP_REPORTER 1 - nsresult - SystemHeapSize(int64_t* aSizeOut) -@@ -172,6 +173,7 @@ SystemHeapSize(int64_t* aSizeOut) - *aSizeOut = size_t(info.hblkhd) + size_t(info.uordblks); - return NS_OK; + # ifdef HAVE_MALLINFO + # define HAVE_SYSTEM_HEAP_REPORTER 1 + static MOZ_MUST_USE nsresult SystemHeapSize(int64_t* aSizeOut) { +@@ -143,6 +144,7 @@ static MOZ_MUST_USE nsresult SystemHeapSize(int64_t* aSizeOut) { + return NS_OK; } + # endif +#endif - - #elif defined(__DragonFly__) || defined(__FreeBSD__) \ - || defined(__NetBSD__) || defined(__OpenBSD__) \ + + #elif defined(__DragonFly__) || defined(__FreeBSD__) || defined(__NetBSD__) || \ + defined(__OpenBSD__) || defined(__FreeBSD_kernel__) diff --git a/testing/thunderbird/mozilla-build-arm.patch b/testing/thunderbird/mozilla-build-arm.patch deleted file mode 100644 index 8b9022ca3c..0000000000 --- a/testing/thunderbird/mozilla-build-arm.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- ./gfx/ycbcr/moz.build.orig 2014-04-03 13:50:38.990296661 +0000 -+++ ./gfx/ycbcr/moz.build 2014-04-03 13:52:26.878268547 +0000 -@@ -53,7 +53,7 @@ else: - 'yuv_row_other.cpp', - ] - --if CONFIG['CPU_ARCH'] == 'arm' and CONFIG['HAVE_ARM_NEON']: -+if CONFIG['HAVE_ARM_NEON']: - SOURCES += [ - 'yuv_row_arm.s', - ] diff --git a/testing/thunderbird/rust-cssparser.patch b/testing/thunderbird/rust-cssparser.patch deleted file mode 100644 index 1fc1805234..0000000000 --- a/testing/thunderbird/rust-cssparser.patch +++ /dev/null @@ -1,92 +0,0 @@ -This is a fix for rust version 1.38.0, which causes the warning below to become an error. - -backport of: - -From 3c98d22c5de3b696bf1fde2b6c90069812312aa6 Mon Sep 17 00:00:00 2001 -From: Simon Sapin <simon.sapin@exyr.org> -Date: Tue, 23 Apr 2019 13:47:25 +0200 -Subject: [PATCH] Fix a future-compat warning - -``` -warning[E0506]: cannot assign to `self.input.cached_token` because it is borrowed - --> src/parser.rs:591:17 - | -566 | pub fn next_including_whitespace_and_comments(&mut self) -> Result<&Token<'i>, BasicParseError<'i>> { - | - let's call the lifetime of this reference `'1` -... -579 | Some(ref cached_token) - | ---------------- borrow of `self.input.cached_token` occurs here -... -591 | self.input.cached_token = Some(CachedToken { - | ^^^^^^^^^^^^^^^^^^^^^^^ assignment to borrowed `self.input.cached_token` occurs here -... -603 | Ok(token) - | --------- returning this value requires that `self.input.cached_token.0` is borrowed for `'1` - | - = warning: this error has been downgraded to a warning for backwards compatibility with previous releases - = warning: this represents potential undefined behavior in your code and this warning will become a hard error in the future -``` ---- - src/parser.rs | 50 +++++++++++++++++++++++++++----------------------- - 1 file changed, 27 insertions(+), 23 deletions(-) - -diff --git a/src/parser.rs b/src/parser.rs -index 51f441e4..7cef117c 100644 ---- a/third_party/rust/cssparser/src/parser.rs -+++ b/third_party/rust/cssparser/src/parser.rs -@@ -555,28 +555,34 @@ - } - - let token_start_position = self.input.tokenizer.position(); -- let token; -- match self.input.cached_token { -- Some(ref cached_token) -- if cached_token.start_position == token_start_position => { -- self.input.tokenizer.reset(&cached_token.end_state); -- match cached_token.token { -- Token::Function(ref name) => self.input.tokenizer.see_function(name), -- _ => {} -- } -- token = &cached_token.token -+ let using_cached_token = self -+ .input -+ .cached_token -+ .as_ref() -+ .map_or(false, |cached_token| { -+ cached_token.start_position == token_start_position -+ }); -+ let token = if using_cached_token { -+ let cached_token = self.input.cached_token.as_ref().unwrap(); -+ self.input.tokenizer.reset(&cached_token.end_state); -+ match cached_token.token { -+ Token::Function(ref name) => self.input.tokenizer.see_function(name), -+ _ => {} - } -- _ => { -- let new_token = self.input.tokenizer.next() -- .map_err(|()| self.new_basic_error(BasicParseErrorKind::EndOfInput))?; -- self.input.cached_token = Some(CachedToken { -- token: new_token, -- start_position: token_start_position, -- end_state: self.input.tokenizer.state(), -- }); -- token = self.input.cached_token_ref() -- } -- } -+ &cached_token.token -+ } else { -+ let new_token = self -+ .input -+ .tokenizer -+ .next() -+ .map_err(|()| self.new_basic_error(BasicParseErrorKind::EndOfInput))?; -+ self.input.cached_token = Some(CachedToken { -+ token: new_token, -+ start_position: token_start_position, -+ end_state: self.input.tokenizer.state(), -+ }); -+ self.input.cached_token_ref() -+ }; - - if let Some(block_type) = BlockType::opening(token) { - self.at_start_of = Some(block_type); diff --git a/testing/thunderbird/rust-unitialized-field.patch b/testing/thunderbird/rust-unitialized-field.patch deleted file mode 100644 index 67ef3a02ab..0000000000 --- a/testing/thunderbird/rust-unitialized-field.patch +++ /dev/null @@ -1,19 +0,0 @@ ---- ./media/audioipc/audioipc/src/cmsg.rs.orig 2018-05-09 22:19:14.748631939 +0200 -+++ ./media/audioipc/audioipc/src/cmsg.rs 2018-05-09 22:19:22.961620862 +0200 -@@ -106,11 +106,11 @@ impl ControlMsgBuilder { - return Err(Error::NoSpace); - } - -- let cmsghdr = cmsghdr { -- cmsg_len: cmsg_len as _, -- cmsg_level: level, -- cmsg_type: kind, -- }; -+ use std::mem; -+ let mut cmsghdr: cmsghdr = unsafe { mem::zeroed() }; -+ cmsghdr.cmsg_len = cmsg_len as _; -+ cmsghdr.cmsg_level = level; -+ cmsghdr.cmsg_type = kind; - - let cmsghdr = unsafe { - slice::from_raw_parts(&cmsghdr as *const _ as *const _, mem::size_of::<cmsghdr>()) diff --git a/testing/thunderbird/rust133.patch b/testing/thunderbird/rust133.patch deleted file mode 100644 index 9ec1e9c265..0000000000 --- a/testing/thunderbird/rust133.patch +++ /dev/null @@ -1,24 +0,0 @@ -This fixes build errors under recent Rust. - ---- a/servo/components/style_traits/lib.rs -+++ b/servo/components/style_traits/lib.rs -@@ -9,7 +9,7 @@ - #![crate_name = "style_traits"] - #![crate_type = "rlib"] - --#![deny(unsafe_code, missing_docs)] -+#![deny(unsafe_code)] - - extern crate app_units; - #[macro_use] extern crate bitflags; ---- a/servo/components/style/lib.rs -+++ b/servo/components/style/lib.rs -@@ -23,8 +23,6 @@ - //! [cssparser]: ../cssparser/index.html - //! [selectors]: ../selectors/index.html - --#![deny(missing_docs)] -- - extern crate app_units; - extern crate arrayvec; - extern crate atomic_refcell; |
