diff options
author | Marius Bakke <marius@gnu.org> | 2020-10-23 10:17:21 +0200 |
---|---|---|
committer | Marius Bakke <marius@gnu.org> | 2020-11-05 02:20:24 +0100 |
commit | 867e3830e6a3ee92317379e33d80c58a57107af4 (patch) | |
tree | a176c19d63d48e668fb01a17409631260fbd9584 /gnu/packages/chromium.scm | |
parent | f7d0a63ddabe864e26bbff8e633371e6ae856845 (diff) | |
download | guix-867e3830e6a3ee92317379e33d80c58a57107af4.tar.gz |
gnu: ungoogled-chromium: Add search path for installed extensions.
* gnu/packages/patches/ungoogled-chromium-extension-search-path.patch: New file. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/chromium.scm (%guix-patches): New variable. (ungoogled-chromium-snippet): Apply %GUIX-PATCHES. (ungoogled-chromium)[arguments]: Don't hard-code extensions directory. [native-search-paths]: New field.
Diffstat (limited to 'gnu/packages/chromium.scm')
-rw-r--r-- | gnu/packages/chromium.scm | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/gnu/packages/chromium.scm b/gnu/packages/chromium.scm index f32a779805..b2191701df 100644 --- a/gnu/packages/chromium.scm +++ b/gnu/packages/chromium.scm @@ -334,6 +334,10 @@ (base32 "18p9a7qffmy8m03nqva7maalgil13lj2mn0s56v3crbs4wk4lalj")))) +(define %guix-patches + (list (local-file (search-patch "ungoogled-chromium-system-nspr.patch")) + (local-file (search-patch "ungoogled-chromium-extension-search-path.patch")))) + ;; This is a source 'snippet' that does the following: ;; *) Applies various patches for unbundling purposes and libstdc++ compatibility. ;; *) Runs the ungoogled patch-, domain substitution-, and scrubbing scripts. @@ -356,9 +360,7 @@ (invoke "patch" "-p1" "--force" "--input" patch "--no-backup-if-mismatch")) (append '#+%debian-patches '#+%arch-patches - '#+(list (local-file - (search-patch - "ungoogled-chromium-system-nspr.patch"))))) + '#+%guix-patches)) (with-directory-excursion #+%ungoogled-origin (format #t "Ungooglifying...~%") @@ -571,11 +573,6 @@ (find-files (string-append "third_party/webrtc/modules" "/audio_coding/codecs/opus"))) - (substitute* "chrome/common/chrome_paths.cc" - (("/usr/share/chromium/extensions") - ;; TODO: Add ~/.guix-profile. - "/run/current-system/profile/share/chromium/extensions")) - ;; Many files try to include ICU headers from "third_party/icu/...". ;; Remove the "third_party/" prefix to use system headers instead. (substitute* (find-files "chrome" "\\.cc$") @@ -840,6 +837,11 @@ ("udev" ,eudev) ("valgrind" ,valgrind) ("vulkan-headers" ,vulkan-headers))) + (native-search-paths + (list (search-path-specification + (variable "CHROMIUM_EXTENSION_DIRECTORY") + (separator #f) ;single entry + (files '("share/chromium/extensions"))))) ;; Building Chromium takes ... a very long time. On a single core, a busy ;; mid-end x86 system may need more than 24 hours to complete the build. |