From 80eedae8968907d755c41ae38a7dc637b0cc7811 Mon Sep 17 00:00:00 2001 From: yangxianzhao Date: Wed, 22 Feb 2023 13:52:11 +0800 Subject: [PATCH] rebrand to anolis fix build error --- download | 1 + ...refs.js => firefox-anolis-default-prefs.js | 6 +-- firefox.spec | 44 +++++++++++++++---- 3 files changed, 39 insertions(+), 12 deletions(-) rename firefox-redhat-default-prefs.js => firefox-anolis-default-prefs.js (91%) diff --git a/download b/download index f010f45..a9b4fb3 100644 --- a/download +++ b/download @@ -4,3 +4,4 @@ d1951406d0044ef0329941d2a2be283d firefox-102.8.0esr.b2.processed-source.tar.xz d41d8cd98f00b204e9800998ecf8427e mochitest-python.tar.gz 75157f5e77e1a4f460645a57ff54e552 nspr-4.34.0-3.el8_1.src.rpm 04f69b8baa7bd8ddc49d786b04307df8 nss-3.79.0-6.el8_1.src.rpm +64e444c5ceddbba10db44d3108809d6c rust-cbindgen.tar.gz diff --git a/firefox-redhat-default-prefs.js b/firefox-anolis-default-prefs.js similarity index 91% rename from firefox-redhat-default-prefs.js rename to firefox-anolis-default-prefs.js index 7bf5098..8d3354e 100644 --- a/firefox-redhat-default-prefs.js +++ b/firefox-anolis-default-prefs.js @@ -14,8 +14,8 @@ pref("browser.shell.checkDefaultBrowser", false); pref("network.manage-offline-status", true); pref("extensions.shownSelectionUI", true); pref("ui.SpellCheckerUnderlineStyle", 1); -pref("startup.homepage_override_url", "http://www.redhat.com"); -pref("startup.homepage_welcome_url", "http://www.redhat.com"); +pref("startup.homepage_override_url", "https://openanolis.cn/"); +pref("startup.homepage_welcome_url", "https://openanolis.cn/"); pref("browser.startup.homepage", "data:text/plain,browser.startup.homepage=file:///%PREFIX%/share/doc/HTML/index.html"); pref("media.gmp-gmpopenh264.provider.enabled",false); pref("media.gmp-gmpopenh264.autoupdate",false); @@ -36,4 +36,4 @@ pref("browser.gnome-search-provider.enabled",true); /* Enable ffvpx playback for WebRTC */ pref("media.navigator.mediadatadecoder_vpx_enabled", true); /* See https://bugzilla.redhat.com/show_bug.cgi?id=1672424 */ -pref("storage.nfs_filesystem", true); \ No newline at end of file +pref("storage.nfs_filesystem", true); diff --git a/firefox.spec b/firefox.spec index a0a8db6..626285f 100644 --- a/firefox.spec +++ b/firefox.spec @@ -1,3 +1,5 @@ +%define anolis_release .0.1 +%global flatpak 1 %global disable_toolsets 0 # Produce a build suitable for release, i.e. use PGO/LTO. You can turn it off # when building locally to reduce build time. @@ -104,7 +106,7 @@ end} %endif %global use_rustts 1 %global dts_version 10 -%global rust_version 1.62 +#%global rust_version 1.62 %if 0%{?rhel} >= 8 %global use_rustts 0 %endif @@ -201,7 +203,7 @@ end} Summary: Mozilla Firefox Web browser Name: firefox Version: 102.8.0 -Release: 2%{?dist} +Release: 2%{anolis_release}%{?dist} URL: https://www.mozilla.org/firefox/ License: MPLv1.1 or GPLv2+ or LGPLv2+ @@ -236,7 +238,7 @@ Source1: firefox-langpacks-%{version}%{?pre_version}-20230214.tar.xz Source2: cbindgen-vendor.tar.xz Source3: process-official-tarball Source10: firefox-mozconfig -Source12: firefox-redhat-default-prefs.js +Source12: firefox-anolis-default-prefs.js Source20: firefox.desktop Source21: firefox.sh.in Source23: firefox.1 @@ -262,6 +264,7 @@ Source45: run-wayland-compositor Source403: nss-3.79.0-6.el8_1.src.rpm Source401: nss-setup-flags-env.inc Source402: nspr-4.34.0-3.el8_1.src.rpm +Source404: rust-cbindgen.tar.gz # Build patches Patch3: mozilla-build-arm.patch @@ -384,7 +387,7 @@ BuildRequires: rustfmt >= %{rust_version} %endif %if 0%{?use_rustts} -BuildRequires: rust-toolset-%{rust_version} +#BuildRequires: rust-toolset-%{rust_version} %endif %if 0%{?use_llvmts} @@ -437,7 +440,7 @@ BuildRequires: python3-devel BuildRequires: python3-setuptools BuildRequires: desktop-file-utils -Requires: redhat-indexhtml +Requires: anolis-indexhtml %if !0%{?flatpak} #TODO @@ -917,8 +920,23 @@ which node mkdir -p my_rust_vendor cd my_rust_vendor %{__tar} xf %{SOURCE2} -mkdir -p .cargo -cat > .cargo/config < %{_buildrootdir}/cargo/config < 7 ln -sf /usr/lib64/libnss3.so %{buildroot}%{_libdir}/libnss3.so +%endif ln -sf /usr/lib64/pkcs11/p11-kit-client.so %{buildroot}%{_libdir}/libnssckbi.so %endif #--------------------------------------------------------------------- @@ -1404,7 +1424,9 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %{mozappdir}/pingsender %exclude %{mozappdir}/removed-files %if 0%{?flatpak} +%if 0%{?rhel} > 7 %{_libdir}/libnss3.so +%endif %{_libdir}/libnssckbi.so %endif %{_datadir}/icons/hicolor/16x16/apps/firefox.png @@ -1453,6 +1475,10 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : #--------------------------------------------------------------------- %changelog +* Wed Feb 22 2022 yangxianzhao - 102.8.0-2 +- rebrand: rebrand for anolis +- feat: fix an7 compile problem + * Tue Feb 14 2023 Eike Rathke - 102.8.0-2 - Update to 102.8.0 build2 -- Gitee