unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Tobias Geerinckx-Rice via Guix-patches via <guix-patches@gnu.org>
To: 39146@debbugs.gnu.org
Cc: "Jakub Kądziołka" <kuba@kadziolka.net>
Subject: [bug#39146] [PATCH] gnu: icecat: Remove about:buildconfig store references.
Date: Wed, 22 Jan 2020 02:34:06 +0100	[thread overview]
Message-ID: <20200122013406.3476-1-me@tobias.gr> (raw)
In-Reply-To: <20200115222115.322ymuuqkwlnbl3v@zdrowyportier.kadziolka.net>

* gnu/packages/gnuzilla.scm (icecat)[arguments]:
New ‘neutralise-store-references’ phase.

Reported-by: Jakub Kądziołka <kuba@kadziolka.net>
---

Jakub, IceCats,

What do you think of this attempt at robustness?  Any drawbacks I've missed?

Kind regards,

T G-R

 gnu/packages/gnuzilla.scm | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/gnu/packages/gnuzilla.scm b/gnu/packages/gnuzilla.scm
index ae0c58eedb..d4a793971c 100644
--- a/gnu/packages/gnuzilla.scm
+++ b/gnu/packages/gnuzilla.scm
@@ -11,6 +11,7 @@
 ;;; 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,15 @@ 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"
+               (("(/gnu/store/)([0-9a-z]{32})" all store hash)
+                (string-append store (string-take hash 8) "…")))
+             #t))
          (add-before 'configure 'install-desktop-entry
            (lambda* (#:key outputs #:allow-other-keys)
              ;; Install the '.desktop' file.
-- 
2.23.0

  parent reply	other threads:[~2020-01-22  1:35 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               ` [bug#39146] [PATCH v3] gnu: icecat: Remove about:buildconfig store references Jakub Kądziołka
2020-02-13 22:03                 ` [bug#39146] [PATCH v4] " 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 ` Tobias Geerinckx-Rice via Guix-patches via [this message]
     [not found]   ` <20200122135107.73z6upacjwial3zq@zdrowyportier.kadziolka.net>
     [not found]     ` <87o8uvlgnn.fsf@nckx>
2020-01-22 14:39       ` [bug#39146] [PATCH] gnu: icecat: Remove about:buildconfig store references 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

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200122013406.3476-1-me@tobias.gr \
    --to=guix-patches@gnu.org \
    --cc=39146@debbugs.gnu.org \
    --cc=kuba@kadziolka.net \
    --cc=me@tobias.gr \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).