GNU bug report logs - #55966
[PATCH 9/9] gnu: chromium extensions lighter make-crx.

Previous Next

Package: guix-patches;

Reported by: Nicolas Graves <ngraves <at> ngraves.fr>

Date: Tue, 14 Jun 2022 09:51:06 UTC

Severity: normal

Tags: patch

Merged with 55958, 55959, 55960, 55961, 55962, 55963, 55964, 55965

Done: Marius Bakke <marius <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #10 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Marius Bakke <marius <at> gnu.org>
To: Nicolas Graves via Guix-patches via <guix-patches <at> gnu.org>,
 55966 <at> debbugs.gnu.org
Cc: Nicolas Graves <ngraves <at> ngraves.fr>
Subject: Re: [bug#55966] [PATCH 9/9] gnu: chromium extensions lighter make-crx.
Date: Thu, 23 Jun 2022 23:20:57 +0200
[Message part 1 (text/plain, inline)]
Nicolas Graves via Guix-patches via <guix-patches <at> gnu.org> skriver:

> ---
>  gnu/build/chromium-extension.scm | 17 +++--------------
>  1 file changed, 3 insertions(+), 14 deletions(-)

This commit lacks a message describing the changed variable.  The commit
title could also be more descriptive.  ;-)

> diff --git a/gnu/build/chromium-extension.scm b/gnu/build/chromium-extension.scm
> index 8ca5251957..8d52153751 100644
> --- a/gnu/build/chromium-extension.scm
> +++ b/gnu/build/chromium-extension.scm
> @@ -19,10 +19,9 @@
>  (define-module (gnu build chromium-extension)
>    #:use-module (guix gexp)
>    #:use-module (guix packages)
> -  #:use-module (gnu packages chromium)
>    #:use-module (gnu packages gnupg)
>    #:use-module (gnu packages tls)
> -  #:use-module (gnu packages xorg)
> +  #:use-module (gnu packages node-xyz)
>    #:use-module (guix build-system trivial)
>    #:export (make-chromium-extension))
>  
> @@ -69,24 +68,14 @@ (define version (package-version package))
>     (string-append name "-" version ".crx")
>     (with-imported-modules '((guix build utils))
>       #~(begin
> -         ;; This is not great.  We pull Xorg and Chromium just to Zip and
> -         ;; sign an extension.  This should be implemented with something
> -         ;; lighter.  (TODO: where is the CRXv3 documentation..?)

Wohoo.  :-)

>           (use-modules (guix build utils))
> -         (let ((chromium #$(file-append ungoogled-chromium "/bin/chromium"))
> -               (xvfb #$(file-append xorg-server "/bin/Xvfb"))
> +         (let ((crx3 #$(file-append node-crx3 "/bin/crx3"))
>                 (packdir (string-append (getcwd) "/extension")))
>             (mkdir packdir)
>             (copy-recursively (ungexp package package-output) packdir
>                               ;; Ensure consistent file modification times.
>                               #:keep-mtime? #t)
> -           (system (string-append xvfb " :1 &"))
> -           (setenv "DISPLAY" ":1")
> -           (sleep 2)                    ;give Xorg some time to initialize...
> -           (invoke chromium
> -                   "--user-data-dir=chromium-profile"
> -                   (string-append "--pack-extension=" packdir)
> -                   (string-append "--pack-extension-key=" #$signing-key))
> +           (invoke crx3 "--keyPath" #$signing-key packdir)

LGTM!  Feel free to add your copyright here too.

Can you send an updated series?

Thanks!
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 3 years and 20 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.