1
Fork 0
mirror of https://https.git.savannah.gnu.org/git/guix.git/ synced 2025-07-12 18:10:47 +02:00
guix/gnu/packages/patches/icecat-use-system-wide-dir.patch
Mark H Weaver c51a40b0c8
gnu: icecat: Update to 128.12.0-gnu1 [security fixes].
Includes fixes for CVE-2025-6424, CVE-2025-6425, CVE-2025-6426,
CVE-2025-6429, and CVE-2025-6430.

* gnu/packages/gnuzilla.scm (mozilla-115-compare-locales)
(mozilla-115-locale, mozilla-115-locales, update-mozilla-115-locales)
(all-mozilla-115-locales, %icecat-115-base-version)
(%icecat-115-version %icecat-115-build-id, icecat-115-source): New
bindings, retaining the previous meanings (before this commit) of
mozilla-compare-locales, mozilla-locale, mozilla-locales,
update-mozilla-locales, all-mozilla-locales, %icecat-base-version,
%icecat-version, %icecat-build-id, and icecat-source, respectively.
(mozilla-locale, mozilla-locales, update-mozilla-locales)
(all-mozilla-locales): Remove bindings.
(mozilla-compare-locales): Switch to new Github URL.
(mozilla-l10n): New variable.
(%icecat-locales): Move definition above "%icecat-base-version".
Add new locales "sat" and "skr".
(%icecat-base-version, %icecat-version, %icecat-build-id): Update.
(icecat-source): Update 'gnuzilla-commit' and hashes.
Remove 'upstream-icecat-base-version' local variable
and associated comments.  Modify the code
within (with-directory-excursion "l10n" ...) to adapt to new
upstream handling of locales.
(icecat-minimal) [inputs]: Switch from 'ffmpeg-5' to 'ffmpeg'.
Update the comment on why we are still using the bundled NSS.
[native-inputs]: Switch from 'rust-cbindgen-0.24' to 'rust-cbindgen'.
[arguments]: Add "--enable-rust-simd" to configure-flags.
Adapt 'remove-cargo-frozen-flag' phase to work on IceCat 128.
(comm-source->locales+changeset): Use 'update-mozilla-115-locales'.
(icedove-source): Use 'icecat-115-source'.
* gnu/packages/patches/icecat-use-system-wide-dir.patch,
gnu/packages/patches/icecat-compare-paths.patch: Adapt to IceCat 128.
* gnu/packages/patches/icecat-102-makeicecat.patch: Delete file
* gnu/local.mk (dist_patch_DATA): Remove it.
2025-06-24 11:12:49 -04:00

36 lines
1.2 KiB
Diff

Replace "/usr/lib/mozilla" (the system-wide directory for extensions and
native manifests) with "$ICECAT_SYSTEM_DIR".
--- a/toolkit/xre/nsXREDirProvider.cpp
+++ b/toolkit/xre/nsXREDirProvider.cpp
@@ -296,24 +296,12 @@ nsresult nsXREDirProvider::GetBackgroundTasksProfilesRootDir(
static nsresult GetSystemParentDirectory(nsIFile** aFile) {
nsresult rv;
nsCOMPtr<nsIFile> localDir;
-# if defined(XP_MACOSX)
- rv = GetOSXFolderType(kOnSystemDisk, kApplicationSupportFolderType,
- getter_AddRefs(localDir));
- if (NS_SUCCEEDED(rv)) {
- rv = localDir->AppendNative("Mozilla"_ns);
- }
-# else
- constexpr auto dirname =
-# ifdef HAVE_USR_LIB64_DIR
- "/usr/lib64/mozilla"_ns
-# elif defined(__OpenBSD__) || defined(__FreeBSD__)
- "/usr/local/lib/mozilla"_ns
-# else
- "/usr/lib/mozilla"_ns
-# endif
- ;
- rv = NS_NewNativeLocalFile(dirname, false, getter_AddRefs(localDir));
-# endif
+
+ const char* systemParentDir = getenv("ICECAT_SYSTEM_DIR");
+ if (!systemParentDir || !*systemParentDir) return NS_ERROR_FAILURE;
+
+ rv = NS_NewNativeLocalFile(nsDependentCString(systemParentDir), false,
+ getter_AddRefs(localDir));
if (NS_SUCCEEDED(rv)) {
localDir.forget(aFile);