diff --git a/firefox/.signature b/firefox/.signature index a5ddaff35..0b7cf4a4f 100644 --- a/firefox/.signature +++ b/firefox/.signature @@ -1,7 +1,9 @@ untrusted comment: verify with /etc/ports/contrib.pub -RWSagIOpLGJF376UBZwv6BYV6JuyRL8jnRNXfVaZFtqbKl/rRHhCKCS8h1iYDvR7cD27rFca1PNkNHKbn0Qn0CRPl/sh1sjg3gU= -SHA256 (Pkgfile) = 373363dded4c117d099b6fc90818062a047111d34a5e8f98ac22b8d39330b775 +RWSagIOpLGJF3yUgdfAY4vHtMV6CevDODZBEnbom03jvyzzrd6tQSqzkY3l2LwLPbG747qPSpKAFu8WFGsnaZgkEaG2cL5PIKg0= +SHA256 (Pkgfile) = dbc5d23540e2598e3f300e84b15dd88e836d1a6f3ad853e78b8b3d684eb03c52 SHA256 (.footprint) = 9df33aad85e11ded757ac494b9d53f882cade01f805dacc3b52e1ed602436bbb SHA256 (firefox-75.0.source.tar.xz) = bbb1054d8f2717c634480556d3753a8483986af7360e023bb6232df80b746b0f SHA256 (firefox.desktop) = 8ba3439f3dfc5cab883641969c93d8d15f8f20d7188d9568346b2edad52d6f91 +SHA256 (0001-Use-remoting-name-for-GDK-application-names.patch) = 5f7ac724a5c5afd9322b1e59006f4170ea5354ca1e0e60dab08b7784c2d8463c +SHA256 (0001-Bug-1623885-Add-subsystem-to-Mesa-sandbox-policy.patch) = ebb169804750ddc10a4801ed6ddb37356331bbf76615f58eb29de2e6e15ee930 SHA256 (fix-unicode-errors.patch) = 47fa576aa3e2dcb1f1d48fa504893bcbe31e7a5fef7c1f2e84570a2692c6794d diff --git a/firefox/0001-Bug-1623885-Add-subsystem-to-Mesa-sandbox-policy.patch b/firefox/0001-Bug-1623885-Add-subsystem-to-Mesa-sandbox-policy.patch new file mode 100644 index 000000000..eb9667476 --- /dev/null +++ b/firefox/0001-Bug-1623885-Add-subsystem-to-Mesa-sandbox-policy.patch @@ -0,0 +1,35 @@ +From 0447215abf836bbb8eef53aeccf029dd40bd1a52 Mon Sep 17 00:00:00 2001 +From: Jeff Gilbert +Date: Sun, 12 Apr 2020 21:21:32 +0000 +Subject: [PATCH] Bug 1623885 - Add "subsystem" to Mesa sandbox policy to fix + libdrm-2.4.101+. r=gcp, a=RyanVM + +Differential Revision: https://phabricator.services.mozilla.com/D70579 +--- + .../linux/broker/SandboxBrokerPolicyFactory.cpp | 10 ++++++---- + 1 file changed, 6 insertions(+), 4 deletions(-) + +diff --git a/security/sandbox/linux/broker/SandboxBrokerPolicyFactory.cpp b/security/sandbox/linux/broker/SandboxBrokerPolicyFactory.cpp +index 3aa7cf27e353..0b3948ebd92e 100644 +--- a/security/sandbox/linux/broker/SandboxBrokerPolicyFactory.cpp ++++ b/security/sandbox/linux/broker/SandboxBrokerPolicyFactory.cpp +@@ -86,10 +86,12 @@ static void AddMesaSysfsPaths(SandboxBroker::Policy* aPolicy) { + // broker. To match this, allow the canonical paths. + UniqueFreePtr realSysPath(realpath(sysPath.get(), nullptr)); + if (realSysPath) { +- static const Array kMesaAttrSuffixes = { +- "revision", "vendor", "device", "subsystem_vendor", +- "subsystem_device", "uevent", "config"}; +- for (const auto attrSuffix : kMesaAttrSuffixes) { ++ constexpr const char* kMesaAttrSuffixes[] = { ++ "config", "device", "revision", ++ "subsystem", "subsystem_device", "subsystem_vendor", ++ "uevent", "vendor", ++ }; ++ for (const auto& attrSuffix : kMesaAttrSuffixes) { + nsPrintfCString attrPath("%s/%s", realSysPath.get(), + attrSuffix); + aPolicy->AddPath(rdonly, attrPath.get()); +-- +2.26.2 + diff --git a/firefox/0001-Use-remoting-name-for-GDK-application-names.patch b/firefox/0001-Use-remoting-name-for-GDK-application-names.patch new file mode 100644 index 000000000..165a532f4 --- /dev/null +++ b/firefox/0001-Use-remoting-name-for-GDK-application-names.patch @@ -0,0 +1,55 @@ +From 83f234464554c7f4393cd1dbdeb3a68d3ae0ccae Mon Sep 17 00:00:00 2001 +From: "Jan Alexander Steffens (heftig)" +Date: Mon, 25 Mar 2019 20:30:11 +0100 +Subject: [PATCH] Use remoting name for GDK application names + +--- + toolkit/xre/nsAppRunner.cpp | 6 +----- + widget/gtk/nsAppShell.cpp | 7 +++---- + 2 files changed, 4 insertions(+), 9 deletions(-) + +diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp +index 984b998133bd..b6c9f013940c 100644 +--- a/toolkit/xre/nsAppRunner.cpp ++++ b/toolkit/xre/nsAppRunner.cpp +@@ -3746,11 +3746,7 @@ int XREMain::XRE_mainStartup(bool* aExitFlag) { + // consistently. + + // Set program name to the one defined in application.ini. +- { +- nsAutoCString program(gAppData->name); +- ToLowerCase(program); +- g_set_prgname(program.get()); +- } ++ g_set_prgname(gAppData->remotingName); + + // Initialize GTK here for splash. + +diff --git a/widget/gtk/nsAppShell.cpp b/widget/gtk/nsAppShell.cpp +index 0daa78fdbbad..49038d0bb1c8 100644 +--- a/widget/gtk/nsAppShell.cpp ++++ b/widget/gtk/nsAppShell.cpp +@@ -24,6 +24,7 @@ + # include "WakeLockListener.h" + #endif + #include "gfxPlatform.h" ++#include "nsAppRunner.h" + #include "ScreenHelperGTK.h" + #include "HeadlessScreenHelper.h" + #include "mozilla/widget/ScreenManager.h" +@@ -175,10 +176,8 @@ nsresult nsAppShell::Init() { + // option when program uses gdk_set_program_class(). + // + // See https://bugzilla.gnome.org/show_bug.cgi?id=747634 +- nsAutoString brandName; +- mozilla::widget::WidgetUtils::GetBrandShortName(brandName); +- if (!brandName.IsEmpty()) { +- gdk_set_program_class(NS_ConvertUTF16toUTF8(brandName).get()); ++ if (gAppData) { ++ gdk_set_program_class(gAppData->remotingName); + } + } + +-- +2.24.0 + diff --git a/firefox/Pkgfile b/firefox/Pkgfile index 8fec200e2..d2fb0709c 100644 --- a/firefox/Pkgfile +++ b/firefox/Pkgfile @@ -6,14 +6,22 @@ name=firefox version=75.0 -release=1 +release=2 source=(https://ftp.mozilla.org/pub/firefox/releases/$version/source/firefox-$version.source.tar.xz firefox.desktop + 0001-Use-remoting-name-for-GDK-application-names.patch + 0001-Bug-1623885-Add-subsystem-to-Mesa-sandbox-policy.patch fix-unicode-errors.patch) build() { cd firefox-$version + # https://bugzilla.mozilla.org/show_bug.cgi?id=1530052 + patch -p1 -i $SRC/0001-Use-remoting-name-for-GDK-application-names.patch + + # https://bugzilla.mozilla.org/show_bug.cgi?id=1627486 + patch -p1 -i $SRC/0001-Bug-1623885-Add-subsystem-to-Mesa-sandbox-policy.patch + # https://bugzilla.mozilla.org/show_bug.cgi?id=1532169 patch -p1 -i $SRC/fix-unicode-errors.patch @@ -49,6 +57,8 @@ cat <<- EOF > .mozconfig ac_add_options --enable-system-pixman ac_add_options --enable-alsa ac_add_options --enable-optimize + ac_add_options --enable-release + ac_add_options --enable-rust-simd ac_add_options --disable-debug-symbols ac_add_options --disable-pulseaudio ac_add_options --enable-official-branding