Subject: bug#61360: closed (Re: bug#61360: [PATCH] gnu: gimp: Don't retain reference on GCC.)

From: [email-masked] (GNU bug Tracking System)
Date: Thu, 02 Mar 2023 03:45:02 +0000

Your bug report

#61360: [PATCH] gnu: gimp: Don't retain reference on GCC.

which was filed against the guix-patches package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
61360: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61360
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#61360: [PATCH] gnu: gimp: Don't retain reference on GCC.
From: 宋文武 <[email-masked]>
To: Christopher Baines <[email-masked]>
Cc: [email-masked], [email-masked]
Date: Thu, 02 Mar 2023 11:44:39 +0800
List-Id: <debbugs-submit.debbugs.gnu.org>

Christopher Baines <[email-masked]> writes:

> iyzsong--- via Guix-patches via <[email-masked]> writes:
>
>> From: 宋文武 <[email-masked]>
>>
>> Partly fixes <https://issues.guix.gnu.org/57677>.
>>
>> * gnu/packages/gimp.scm (gimp)[arguments]: Add #:modules and #:phases.
>> ---
>>  gnu/packages/gimp.scm | 13 +++++++++++++
>>  1 file changed, 13 insertions(+)
>
> I don't quite get what's going on here, but it seems good to push.
>

Pushed, thank you!

Subject: [PATCH] gnu: gimp: Don't retain reference on GCC.
From: [email-masked]
To: [email-masked]
Cc: 宋文武 <[email-masked]>
Date: Wed, 8 Feb 2023 15:09:30 +0800
List-Id: <debbugs-submit.debbugs.gnu.org>

From: 宋文武 <[email-masked]>

Partly fixes <https://issues.guix.gnu.org/57677>.

* gnu/packages/gimp.scm (gimp)[arguments]: Add #:modules and #:phases.
---
 gnu/packages/gimp.scm | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/gnu/packages/gimp.scm b/gnu/packages/gimp.scm
index beb43f0ae2..69281f98e9 100644
--- a/gnu/packages/gimp.scm
+++ b/gnu/packages/gimp.scm
@@ -302,6 +302,19 @@ (define-public gimp
                "doc"))                  ; 9 MiB of gtk-doc HTML
     (arguments
      (list
+      #:modules `((ice-9 popen)
+                  (ice-9 rdelim)
+                  ,@%gnu-build-system-modules)
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'remove-gcc-reference
+            ;; Avoid reference to GCC.
+            (lambda _
+              (let* ((port (open-input-pipe "gcc -v 2>&1 | tail -n 1"))
+                     (cc-version (read-line port)))
+                (close-pipe port)
+                (substitute* "app/gimp-version.c"
+                  (("CC_VERSION") (string-append "\"" cc-version "\"")))))))
       #:configure-flags
       #~(list (string-append "--with-html-dir=" #$output "/share/gtk-doc/html")
 
-- 
2.39.1