From: "Jakub Kądziołka" <kuba@kadziolka.net>
To: 39146@debbugs.gnu.org
Cc: Mark H Weaver <mhw@netris.org>,
Marius Bakke <mbakke@fastmail.com>,
Tobias Geerinckx-Rice <me@tobias.gr>,
Danny Milosavljevic <dannym@scratchpost.org>
Subject: [bug#39146] [PATCH v3] gnu: icecat: Remove about:buildconfig store references.
Date: Wed, 12 Feb 2020 20:45:25 +0100 [thread overview]
Message-ID: <20200212194525.joyg66cikh5xfnuu@gravity> (raw)
In-Reply-To: <1581371371.3276.1@tobias.gr>
[-- Attachment #1: Type: text/plain, Size: 3037 bytes --]
* gnu/packages/gnuzilla.scm (icecat)[arguments]:
New ‘neutralise-store-references’ phase.
Co-authored-by: Tobias Geerinckx-Rice <me@tobias.gr>
---
On Mon, Feb 10, 2020 at 10:49:31PM +0100, Tobias Geerinckx-Rice wrote:
> The truncation of these very long paths was fully intended as a feature, but
> if people do think they're actually useful I think this is a clever hack
> worthy of Guix :-)
>
> Have you tested whether copying & pasting still works fine with this?
At the time it was just a rough idea, but here's a patch. After waiting
a while for IceCat to compile, I tested this and it's working
flawlessly. Selection and copy-paste are unhindered.
In the end, I decided to use a comment instead of an empty span, since
it'll be less mysterious should someone stumble upon it. It's also more
greppable.
(to be clear, I only tested the comment version, so perhaps the <span>
one wouldn't have even worked. Not that it matters...)
BTW, do you happen to know a good way to send a patch as a reply? I
ended up using `neomutt -H' and then specifying all the CC's manually...
gnu/packages/gnuzilla.scm | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/gnuzilla.scm b/gnu/packages/gnuzilla.scm
index ae0c58eedb..114e5e636c 100644
--- a/gnu/packages/gnuzilla.scm
+++ b/gnu/packages/gnuzilla.scm
@@ -7,10 +7,11 @@
;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
;;; Copyright © 2017 ng0 <ng0@n0.is>
-;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
+;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2019 Ivan Petkov <ivanppetkov@gmail.com>
;;; Copyright © 2020 Oleg Pykhalov <go.wigust@gmail.com>
+;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -1067,6 +1068,17 @@ from forcing GEXP-PROMISE."
(force-output)
(retry (- remaining-attempts 1))))
(apply build args)))))))
+ (add-after 'build 'neutralise-store-references
+ (lambda _
+ ;; Mangle the store references to compilers & other build tools in
+ ;; about:buildconfig, reducing IceCat's closure by 1 GiB on x86-64.
+ (substitute*
+ "dist/bin/chrome/toolkit/content/global/buildconfig.html"
+ (((format #f "(~a/)([0-9a-z]{32})" (%store-directory)) _ store hash)
+ (string-append store (string-take hash 8)
+ "<!-- Guix: not a runtime dependency -->"
+ (string-drop hash 8))))
+ #t))
(add-before 'configure 'install-desktop-entry
(lambda* (#:key outputs #:allow-other-keys)
;; Install the '.desktop' file.
--
2.25.0
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2020-02-12 19:45 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-15 22:21 [bug#39146] [PATCH] gnu: icecat: Remove compiler paths from about:buildconfig Jakub Kądziołka
2020-01-21 17:37 ` [bug#39146] [PATCH v2] " Jakub Kądziołka
2020-01-21 17:52 ` Danny Milosavljevic
2020-01-22 21:23 ` Mark H Weaver
2020-01-23 8:37 ` Jakub Kądziołka
2020-01-24 2:53 ` Mark H Weaver
2020-02-10 18:38 ` Jakub Kądziołka
2020-02-10 20:24 ` Mark H Weaver
2020-02-10 21:49 ` Tobias Geerinckx-Rice via Guix-patches via
2020-02-12 19:45 ` Jakub Kądziołka [this message]
2020-02-13 22:03 ` [bug#39146] [PATCH v4] gnu: icecat: Remove about:buildconfig store references Jakub Kądziołka
2020-01-21 18:05 ` [bug#39146] [PATCH v2] gnu: icecat: Remove compiler paths from about:buildconfig Tobias Geerinckx-Rice via Guix-patches via
2020-01-22 1:34 ` [bug#39146] [PATCH] gnu: icecat: Remove about:buildconfig store references Tobias Geerinckx-Rice via Guix-patches via
[not found] ` <20200122135107.73z6upacjwial3zq@zdrowyportier.kadziolka.net>
[not found] ` <87o8uvlgnn.fsf@nckx>
2020-01-22 14:39 ` Jakub Kądziołka
2020-01-22 20:13 ` [bug#39146] [PATCH v2] " Tobias Geerinckx-Rice via Guix-patches via
2020-01-22 20:28 ` Marius Bakke
2020-01-22 20:50 ` Jakub Kądziołka
2020-02-26 21:33 ` bug#39146: Done: " Jakub Kądziołka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200212194525.joyg66cikh5xfnuu@gravity \
--to=kuba@kadziolka.net \
--cc=39146@debbugs.gnu.org \
--cc=dannym@scratchpost.org \
--cc=mbakke@fastmail.com \
--cc=me@tobias.gr \
--cc=mhw@netris.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.