GNU bug report logs - #76572
[PATCH 0/4] Fixes for gnome-shell-extension-gsconnect

Previous Next

Package: guix-patches;

Reported by: aurtzy <aurtzy <at> gmail.com>

Date: Tue, 25 Feb 2025 23:27:01 UTC

Severity: normal

Tags: patch

Done: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: aurtzy <aurtzy <at> gmail.com>
To: 76572 <at> debbugs.gnu.org
Cc: aurtzy <aurtzy <at> gmail.com>, aurtzy <aurtzy <at> gmail.com>, Maxim Cournoyer <maxim.cournoyer <at> gmail.com>, Liliana Marie Prikler <liliana.prikler <at> gmail.com>, Vivien Kraus <vivien <at> planete-kraus.eu>
Subject: [bug#76572] [PATCH v2 3/4] gnu: gnome-shell-extension-gsconnect: Patch shebangs with gjs.
Date: Thu,  6 Mar 2025 03:44:52 -0500
The 'patch-shebangs phase does not handle shebangs of the form
"/usr/bin/env -S", so we manually patch them to fix a not-found error.

* gnu/packages/gnome-xyz.scm (gnome-shell-extension-gsconnect):
[arguments]<#:phases>: Add 'patch-gjs-shebangs phase to patch shebangs using
"/usr/bin/env -S" to execute gjs.

Change-Id: I6b84474e4976484f1203b7cf78fe5e882694cd22
---
 gnu/packages/gnome-xyz.scm | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/gnu/packages/gnome-xyz.scm b/gnu/packages/gnome-xyz.scm
index 359dc757fd..09e73a9c0a 100644
--- a/gnu/packages/gnome-xyz.scm
+++ b/gnu/packages/gnome-xyz.scm
@@ -761,6 +761,19 @@ (define-public gnome-shell-extension-gsconnect
                  "gtk_update_icon_cache: false")
                 (("update_desktop_database: true")
                  "update_desktop_database: false"))))
+          ;; TODO: Remove after 'patch-shebangs is fixed to handle '/usr/bin/env -S'
+          ;; shebangs (see bug#74450).
+          (add-after 'unpack 'patch-gjs-shebangs
+            (lambda* (#:key inputs #:allow-other-keys)
+              (for-each (lambda (file)
+                          (substitute* file
+                            (("^#!/usr/bin/env -S gjs.*$")
+                             (string-append "#!" (which "gjs") " -m"))))
+                        '("installed-tests/minijasmine"
+                          "src/gsconnect-preferences"
+                          "src/service/nativeMessagingHost.js"
+                          "src/service/daemon.js"
+                          "webextension/gettext.js"))))
           (add-before 'configure 'fix-paths
             (lambda* (#:key inputs #:allow-other-keys)
               (let ((gapplication (search-input-file inputs "/bin/gapplication"))
-- 
2.48.1





This bug report was last modified 76 days ago.

Previous Next


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