Skip to content

Commit

Permalink
www/firefox: update to 96.0.3
Browse files Browse the repository at this point in the history
PR:		261410
Reported by:	Stefan Ehmann
Tested by:	Stefan Ehmann (prior v0.3),
		jbeich (PipeWire screen capture) (prior v0.8 via mail),
		cmt (prior v0.8 + 96.0.3 bump)
  • Loading branch information
ekhramtsov authored and moench-tegeder committed Jan 28, 2022
1 parent c77f337 commit 7b007c9
Show file tree
Hide file tree
Showing 19 changed files with 253,299 additions and 26,330 deletions.
3 changes: 3 additions & 0 deletions Mk/bsd.gecko.mk
Expand Up @@ -67,6 +67,9 @@ USE_GL= gl
USE_GNOME= cairo gdkpixbuf2 gtk30
USE_PERL5= build
USE_XORG= x11 xcb xcomposite xdamage xext xfixes xrender xt
.if ${MOZILLA_VER:R:R} >= 96
USE_XORG+= xrandr
.endif
HAS_CONFIGURE= yes
CONFIGURE_OUTSOURCE= yes
LDFLAGS+= -Wl,--as-needed
Expand Down
7 changes: 3 additions & 4 deletions www/firefox/Makefile
@@ -1,8 +1,7 @@
# Created by: Alan Eldridge <alane@FreeBSD.org>

PORTNAME= firefox
DISTVERSION= 95.0.2
PORTREVISION= 2
DISTVERSION= 96.0.3
PORTEPOCH= 2
CATEGORIES= www
MASTER_SITES= MOZILLA/${PORTNAME}/releases/${DISTVERSION}/source \
Expand All @@ -13,8 +12,8 @@ MAINTAINER= gecko@FreeBSD.org
COMMENT= Web browser based on the browser portion of Mozilla

BUILD_DEPENDS= nspr>=4.32:devel/nspr \
nss>=3.72:security/nss \
icu>=69.1,1:devel/icu \
nss>=3.73:security/nss \
icu>=70.1:devel/icu \
libevent>=2.1.8:devel/libevent \
harfbuzz>=2.9.1:print/harfbuzz \
graphite2>=1.3.14:graphics/graphite2 \
Expand Down
6 changes: 3 additions & 3 deletions www/firefox/distinfo
@@ -1,3 +1,3 @@
TIMESTAMP = 1639939431
SHA256 (firefox-95.0.2.source.tar.xz) = c178cbf61979bd39a8daa9a09c6e03089da37baded692ad1f745ecfcaae74d64
SIZE (firefox-95.0.2.source.tar.xz) = 384674224
TIMESTAMP = 1643336011
SHA256 (firefox-96.0.3.source.tar.xz) = 1a741d6fcf20e6833a90169f41d29141ea4610f58b848e06091a683af6304dea
SIZE (firefox-96.0.3.source.tar.xz) = 406721708
16 changes: 8 additions & 8 deletions www/firefox/files/patch-addon-search
Expand Up @@ -2,10 +2,10 @@ https://github.com/mozilla/addons/issues/708
https://github.com/mozilla/addons-frontend/issues/4610

diff --git browser/app/profile/firefox.js browser/app/profile/firefox.js
index 75c2c5e435e35..4d8c09c02759b 100644
index af08811..77a3b18 100644
--- browser/app/profile/firefox.js
+++ browser/app/profile/firefox.js
@@ -39,7 +39,7 @@ pref("extensions.postDownloadThirdPartyPrompt", true);
@@ -38,7 +38,7 @@ pref("extensions.postDownloadThirdPartyPrompt", true);
// Preferences for AMO integration
pref("extensions.getAddons.cache.enabled", true);
pref("extensions.getAddons.get.url", "https://services.addons.mozilla.org/api/v4/addons/search/?guid=%IDS%&lang=%LOCALE%");
Expand All @@ -14,7 +14,7 @@ index 75c2c5e435e35..4d8c09c02759b 100644
pref("extensions.getAddons.link.url", "https://addons.mozilla.org/%LOCALE%/firefox/");
pref("extensions.getAddons.langpacks.url", "https://services.addons.mozilla.org/api/v4/addons/language-tools/?app=firefox&type=language&appversion=%VERSION%");
pref("extensions.getAddons.discovery.api_url", "https://services.addons.mozilla.org/api/v4/discovery/?lang=%LOCALE%&edition=%DISTRIBUTION%");
@@ -176,8 +176,8 @@ pref("app.update.langpack.enabled", true);
@@ -193,8 +193,8 @@ pref("app.update.langpack.enabled", true);
// .. etc ..
//
pref("extensions.update.enabled", true);
Expand All @@ -26,10 +26,10 @@ index 75c2c5e435e35..4d8c09c02759b 100644
// Themes every day

diff --git toolkit/mozapps/extensions/internal/AddonRepository.jsm toolkit/mozapps/extensions/internal/AddonRepository.jsm
index f70fd8d7e3bd8..81e8cd7764fdf 100644
index 661c902..a41b32f 100644
--- toolkit/mozapps/extensions/internal/AddonRepository.jsm
+++ toolkit/mozapps/extensions/internal/AddonRepository.jsm
@@ -602,7 +602,7 @@ var AddonRepository = {
@@ -592,7 +592,7 @@ var AddonRepository = {
addon.version = String(aEntry.current_version.version);
if (Array.isArray(aEntry.current_version.files)) {
for (let file of aEntry.current_version.files) {
Expand All @@ -39,15 +39,15 @@ index f70fd8d7e3bd8..81e8cd7764fdf 100644
addon.sourceURI = NetUtil.newURI(file.url);
}
diff --git toolkit/mozapps/extensions/internal/XPIDatabase.jsm toolkit/mozapps/extensions/internal/XPIDatabase.jsm
index f70fd8d7e3bd8..81e8cd7764fdf 100644
index f8c99c7..c6ba8a1 100644
--- toolkit/mozapps/extensions/internal/XPIDatabase.jsm
+++ toolkit/mozapps/extensions/internal/XPIDatabase.jsm
@@ -355,7 +355,7 @@ class AddonInternal {
@@ -520,7 +520,7 @@ class AddonInternal {
// Something is causing errors in here
try {
for (let platform of this.targetPlatforms) {
- if (platform.os == Services.appinfo.OS) {
+ if (platform.os == "Linux" || platform.os == Services.appinfo.OS) {
if (platform.abi) {
needsABI = true;
if (platform.abi === abi)
if (platform.abi === abi) {
14 changes: 8 additions & 6 deletions www/firefox/files/patch-browser-app-nsBrowserApp.cpp
@@ -1,12 +1,14 @@
--- browser/app/nsBrowserApp.cpp.orig 2016-09-19 16:19:28 UTC
diff --git browser/app/nsBrowserApp.cpp browser/app/nsBrowserApp.cpp
index 87c2e16..a41f1d9 100644
--- browser/app/nsBrowserApp.cpp
+++ browser/app/nsBrowserApp.cpp
@@ -324,6 +324,9 @@ int main(int argc, char* argv[], char* e
{
mozilla::TimeStamp start = mozilla::TimeStamp::Now();
@@ -337,6 +337,9 @@ int main(int argc, char* argv[], char* envp[]) {
}
#endif

+ setenv("MOZ_GMP_PATH", "%%LOCALBASE%%/lib/browser_plugins/symlinks/gecko", 0);
+ setenv("MOZ_PLUGIN_PATH", "%%LOCALBASE%%/lib/browser_plugins/symlinks/gecko", 0);
+
#ifdef HAS_DLL_BLOCKLIST
DllBlocklist_Initialize();

DllBlocklist_Initialize(gBlocklistInitFlags);
#endif
37 changes: 0 additions & 37 deletions www/firefox/files/patch-bug1288587

This file was deleted.

10 changes: 6 additions & 4 deletions www/firefox/files/patch-bug1504834_comment10
Expand Up @@ -14,10 +14,11 @@ Solution: This is not a real solution, but a hack. The real solution would have
are readable, albeit not as pretty to look at as they could be.
Side-effects: I have not yet found an unwanted side-effect.

diff -r 46ea866ca3ac -r 6ef20eee3f8f gfx/2d/DrawTargetSkia.cpp
--- gfx/2d/DrawTargetSkia.cpp Tue Oct 22 12:27:22 2019 +0200
+++ gfx/2d/DrawTargetSkia.cpp Thu Oct 31 09:11:56 2019 +0100
@@ -1861,6 +1861,14 @@
diff --git gfx/2d/DrawTargetSkia.cpp gfx/2d/DrawTargetSkia.cpp
index 6bbef8d..161b96f 100644
--- gfx/2d/DrawTargetSkia.cpp
+++ gfx/2d/DrawTargetSkia.cpp
@@ -1903,6 +1903,14 @@ void DrawTargetSkia::PushLayerWithBlend(bool aOpaque, Float aOpacity,
SkCanvas::kPreserveLCDText_SaveLayerFlag |
(aCopyBackground ? SkCanvas::kInitWithPrevious_SaveLayerFlag : 0));

Expand All @@ -32,3 +33,4 @@ diff -r 46ea866ca3ac -r 6ef20eee3f8f gfx/2d/DrawTargetSkia.cpp
mCanvas->saveLayer(saveRec);

SetPermitSubpixelAA(aOpaque);

71 changes: 38 additions & 33 deletions www/firefox/files/patch-bug1504834_comment5
Expand Up @@ -3,9 +3,44 @@ https://bugzilla.mozilla.org/attachment.cgi?id=9028600
Rough progress patch


diff -r 53107afbc21e gfx/skia/skia/third_party/skcms/skcms.cc
--- gfx/skia/skia/third_party/skcms/skcms.cc Wed Nov 07 04:50:21 2018 +0000
+++ gfx/skia/skia/third_party/skcms/skcms.cc Thu Nov 29 12:49:35 2018 +0000
diff --git gfx/2d/DrawTargetSkia.cpp gfx/2d/DrawTargetSkia.cpp
index 6bbef8d..82b04ba 100644
--- gfx/2d/DrawTargetSkia.cpp
+++ gfx/2d/DrawTargetSkia.cpp
@@ -154,8 +154,7 @@ static IntRect CalculateSurfaceBounds(const IntSize& aSize, const Rect* aBounds,
return surfaceBounds.Intersect(bounds);
}

-static const int kARGBAlphaOffset =
- SurfaceFormat::A8R8G8B8_UINT32 == SurfaceFormat::B8G8R8A8 ? 3 : 0;
+static const int kARGBAlphaOffset = 0;

static bool VerifyRGBXFormat(uint8_t* aData, const IntSize& aSize,
const int32_t aStride, SurfaceFormat aFormat) {
diff --git gfx/2d/Types.h gfx/2d/Types.h
index 6b3bdc7..7c6c342 100644
--- gfx/2d/Types.h
+++ gfx/2d/Types.h
@@ -90,15 +90,8 @@ enum class SurfaceFormat : int8_t {
// The following values are endian-independent synonyms. The _UINT32 suffix
// indicates that the name reflects the layout when viewed as a uint32_t
// value.
-#if MOZ_LITTLE_ENDIAN()
A8R8G8B8_UINT32 = B8G8R8A8, // 0xAARRGGBB
X8R8G8B8_UINT32 = B8G8R8X8, // 0x00RRGGBB
-#elif MOZ_BIG_ENDIAN()
- A8R8G8B8_UINT32 = A8R8G8B8, // 0xAARRGGBB
- X8R8G8B8_UINT32 = X8R8G8B8, // 0x00RRGGBB
-#else
-# error "bad endianness"
-#endif

// The following values are OS and endian-independent synonyms.
//
diff --git gfx/skia/skia/third_party/skcms/skcms.cc gfx/skia/skia/third_party/skcms/skcms.cc
index 6b4d87b..7c0559d 100644
--- gfx/skia/skia/third_party/skcms/skcms.cc
+++ gfx/skia/skia/third_party/skcms/skcms.cc
@@ -30,6 +30,8 @@
#include <avx512fintrin.h>
#include <avx512dqintrin.h>
Expand Down Expand Up @@ -48,33 +83,3 @@ diff -r 53107afbc21e gfx/skia/skia/third_party/skcms/skcms.cc
#endif
}

--- gfx/2d/DrawTargetSkia.cpp.orig 2019-09-21 15:51:04.129603000 +0200
+++ gfx/2d/DrawTargetSkia.cpp 2019-09-21 15:52:11.900316000 +0200
@@ -138,8 +138,7 @@ static IntRect CalculateSurfaceBounds(const IntSize& a
return surfaceBounds.Intersect(bounds);
}

-static const int kARGBAlphaOffset =
- SurfaceFormat::A8R8G8B8_UINT32 == SurfaceFormat::B8G8R8A8 ? 3 : 0;
+static const int kARGBAlphaOffset = 0;

static bool VerifyRGBXFormat(uint8_t* aData, const IntSize& aSize,
const int32_t aStride, SurfaceFormat aFormat) {
--- gfx/2d/Types.h.orig 2019-09-21 15:52:47.044803000 +0200
+++ gfx/2d/Types.h 2019-09-21 15:53:40.113641000 +0200
@@ -87,15 +87,8 @@ enum class SurfaceFormat : int8_t {
// The following values are endian-independent synonyms. The _UINT32 suffix
// indicates that the name reflects the layout when viewed as a uint32_t
// value.
-#if MOZ_LITTLE_ENDIAN()
A8R8G8B8_UINT32 = B8G8R8A8, // 0xAARRGGBB
X8R8G8B8_UINT32 = B8G8R8X8, // 0x00RRGGBB
-#elif MOZ_BIG_ENDIAN()
- A8R8G8B8_UINT32 = A8R8G8B8, // 0xAARRGGBB
- X8R8G8B8_UINT32 = X8R8G8B8, // 0x00RRGGBB
-#else
-# error "bad endianness"
-#endif

// The following values are OS and endian-independent synonyms.
//
24 changes: 12 additions & 12 deletions www/firefox/files/patch-bug1559213
Expand Up @@ -11,10 +11,10 @@ Date: Thu Jun 13 11:53:00 2019 -0700
4 files changed, 34 insertions(+), 3 deletions(-)

diff --git config/external/moz.build config/external/moz.build
index 03e4fa143bd1..a67d10b11fe6 100644
index ab77121..75595d9 100644
--- config/external/moz.build
+++ config/external/moz.build
@@ -40,8 +40,9 @@ if not CONFIG["MOZ_SYSTEM_LIBVPX"]:
@@ -49,8 +49,9 @@ if not CONFIG["MOZ_SYSTEM_LIBVPX"]:
external_dirs += ["media/libvpx"]

if CONFIG["MOZ_AV1"]:
Expand All @@ -27,11 +27,11 @@ index 03e4fa143bd1..a67d10b11fe6 100644
if not CONFIG["MOZ_SYSTEM_PNG"]:
external_dirs += ["media/libpng"]
diff --git config/system-headers.mozbuild config/system-headers.mozbuild
index bcf5c4925564..48964a999a9b 100644
index a1b58eb..65729f9 100644
--- config/system-headers.mozbuild
+++ config/system-headers.mozbuild
@@ -1305,6 +1305,14 @@ if CONFIG['MOZ_SYSTEM_HARFBUZZ']:
'harfbuzz/hb.h',
@@ -1289,6 +1289,14 @@ if CONFIG['MOZ_ENABLE_LIBPROXY']:
'proxy.h',
]

+if CONFIG['MOZ_SYSTEM_AV1']:
Expand All @@ -46,7 +46,7 @@ index bcf5c4925564..48964a999a9b 100644
system_headers += [
'vpx_mem/vpx_mem.h',
diff --git dom/media/platforms/moz.build dom/media/platforms/moz.build
index 092cee0c9b66..38e45de5b5f0 100644
index 8509aec..eb6f129 100644
--- dom/media/platforms/moz.build
+++ dom/media/platforms/moz.build
@@ -78,6 +78,11 @@ if CONFIG["MOZ_AV1"]:
Expand All @@ -62,10 +62,10 @@ index 092cee0c9b66..38e45de5b5f0 100644
if CONFIG["MOZ_OMX"]:
EXPORTS += [
diff --git toolkit/moz.configure toolkit/moz.configure
index 82b5a59acf42..e2329560b42b 100644
--- toolkit/moz.configure.orig 2021-04-13 16:12:34.770032000 +0200
+++ toolkit/moz.configure 2021-04-18 00:03:41.432698000 +0200
@@ -538,7 +538,23 @@
index 0069865..e806fc8 100644
--- toolkit/moz.configure
+++ toolkit/moz.configure
@@ -523,7 +523,23 @@ def av1(value):
return True


Expand All @@ -90,11 +90,11 @@ index 82b5a59acf42..e2329560b42b 100644
def dav1d_asm(target):
if target.cpu in ("aarch64", "x86", "x86_64"):
return True
@@ -554,6 +570,7 @@
@@ -539,6 +555,7 @@ set_config("MOZ_DAV1D_ASM", dav1d_asm)
set_define("MOZ_DAV1D_ASM", dav1d_asm)
set_config("MOZ_AV1", av1)
set_define("MOZ_AV1", av1)
+set_config("MOZ_SYSTEM_AV1", depends_if(system_av1)(lambda _: True))

# Built-in fragmented MP4 support.
# JXL Image Codec Support
# ==============================================================

0 comments on commit 7b007c9

Please sign in to comment.