From patchwork Thu May 11 14:54:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christopher Baines X-Patchwork-Id: 49936 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 1F5F227BBF1; Thu, 11 May 2023 15:55:22 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 773DC27BBEE for ; Thu, 11 May 2023 15:55:21 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1px7hB-0000Lq-24; Thu, 11 May 2023 10:55:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1px7h8-0000Ld-NY for guix-patches@gnu.org; Thu, 11 May 2023 10:55:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1px7h8-0006aK-F8 for guix-patches@gnu.org; Thu, 11 May 2023 10:55:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1px7h8-0003Fx-BQ for guix-patches@gnu.org; Thu, 11 May 2023 10:55:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#63416] [PATCH v2 1/2] gnu: gcc: Change custom-gcc to use gexp's. References: <87o7ms1if5.fsf@cbaines.net> In-Reply-To: <87o7ms1if5.fsf@cbaines.net> Resent-From: Christopher Baines Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 11 May 2023 14:55:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63416 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 63416@debbugs.gnu.org Received: via spool by 63416-submit@debbugs.gnu.org id=B63416.168381685612355 (code B ref 63416); Thu, 11 May 2023 14:55:02 +0000 Received: (at 63416) by debbugs.gnu.org; 11 May 2023 14:54:16 +0000 Received: from localhost ([127.0.0.1]:53122 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1px7gO-0003DC-9f for submit@debbugs.gnu.org; Thu, 11 May 2023 10:54:16 -0400 Received: from mira.cbaines.net ([212.71.252.8]:42520) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1px7gL-0003Cq-MS for 63416@debbugs.gnu.org; Thu, 11 May 2023 10:54:14 -0400 Received: from localhost (unknown [IPv6:2a02:8010:68c1:0:3a91:a0a4:ecee:f157]) by mira.cbaines.net (Postfix) with ESMTPSA id 9A95C27BBEE for <63416@debbugs.gnu.org>; Thu, 11 May 2023 15:54:11 +0100 (BST) Received: from localhost (localhost [local]) by localhost (OpenSMTPD) with ESMTPA id 66b6bfd5 for <63416@debbugs.gnu.org>; Thu, 11 May 2023 14:54:10 +0000 (UTC) From: Christopher Baines Date: Thu, 11 May 2023 15:54:09 +0100 Message-Id: <0c9c655159c65003e63d7ddc9f69a87608ae7ccd.1683816850.git.mail@cbaines.net> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches As this seems to be generating broken derivations for i586-gnu otherwise. * gnu/packages/gcc.scm (custom-gcc): Use gexp's for the generated package arguments. --- gnu/packages/gcc.scm | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) base-commit: 4557c83a7d9df6edc9dd3b7b2a53e1a0ec3e6e34 diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm index 47fb443155..1db37529f7 100644 --- a/gnu/packages/gcc.scm +++ b/gnu/packages/gcc.scm @@ -1043,18 +1043,18 @@ (define* (custom-gcc gcc name languages (srfi srfi-26) (ice-9 regex))) ((#:configure-flags flags) - `(cons (string-append "--enable-languages=" - ,(string-join languages ",")) - (remove (cut string-match "--enable-languages.*" <>) - ,flags))) + #~(cons (string-append "--enable-languages=" + #$(string-join languages ",")) + (remove (cut string-match "--enable-languages.*" <>) + #$flags))) ((#:phases phases) - `(modify-phases ,phases - (add-after 'install 'remove-broken-or-conflicting-files - (lambda* (#:key outputs #:allow-other-keys) - (for-each - delete-file - (find-files (string-append (assoc-ref outputs "out") "/bin") - ".*(c\\+\\+|cpp|g\\+\\+|gcov|gcc|lto)(-.*)?$")))))))))) + #~(modify-phases #$phases + (add-after 'install 'remove-broken-or-conflicting-files + (lambda* (#:key outputs #:allow-other-keys) + (for-each + delete-file + (find-files (string-append (assoc-ref outputs "out") "/bin") + ".*(c\\+\\+|cpp|g\\+\\+|gcov|gcc|lto)(-.*)?$")))))))))) (define %generic-search-paths ;; This is the language-neutral search path for GCC. Entries in $CPATH are From patchwork Thu May 11 14:54:10 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christopher Baines X-Patchwork-Id: 49935 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 0AC9927BBF0; Thu, 11 May 2023 15:55:20 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 3A13627BBEE for ; Thu, 11 May 2023 15:55:18 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1px7hB-0000MA-IS; Thu, 11 May 2023 10:55:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1px7h8-0000LW-Bl for guix-patches@gnu.org; Thu, 11 May 2023 10:55:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1px7h8-0006a3-3X for guix-patches@gnu.org; Thu, 11 May 2023 10:55:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1px7h7-0003Fo-Uv for guix-patches@gnu.org; Thu, 11 May 2023 10:55:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#63416] [PATCH v2 2/2] gnu: gcc: Change make-gccgo to use gexp's. Resent-From: Christopher Baines Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 11 May 2023 14:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63416 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 63416@debbugs.gnu.org Received: via spool by 63416-submit@debbugs.gnu.org id=B63416.168381685512346 (code B ref 63416); Thu, 11 May 2023 14:55:01 +0000 Received: (at 63416) by debbugs.gnu.org; 11 May 2023 14:54:15 +0000 Received: from localhost ([127.0.0.1]:53120 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1px7gM-0003D4-QM for submit@debbugs.gnu.org; Thu, 11 May 2023 10:54:15 -0400 Received: from mira.cbaines.net ([212.71.252.8]:42522) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1px7gK-0003Cr-H6 for 63416@debbugs.gnu.org; Thu, 11 May 2023 10:54:13 -0400 Received: from localhost (unknown [IPv6:2a02:8010:68c1:0:3a91:a0a4:ecee:f157]) by mira.cbaines.net (Postfix) with ESMTPSA id B953027BBF0 for <63416@debbugs.gnu.org>; Thu, 11 May 2023 15:54:11 +0100 (BST) Received: from localhost (localhost [local]) by localhost (OpenSMTPD) with ESMTPA id 7ba22d0b for <63416@debbugs.gnu.org>; Thu, 11 May 2023 14:54:10 +0000 (UTC) From: Christopher Baines Date: Thu, 11 May 2023 15:54:10 +0100 Message-Id: X-Mailer: git-send-email 2.39.1 In-Reply-To: <0c9c655159c65003e63d7ddc9f69a87608ae7ccd.1683816850.git.mail@cbaines.net> References: <0c9c655159c65003e63d7ddc9f69a87608ae7ccd.1683816850.git.mail@cbaines.net> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches As otherwise this seems to generate broken derivations for i586-gnu. * gnu/packages/gcc.scm (make-gccgo): Use gexp's for the package arguments. --- gnu/packages/gcc.scm | 56 ++++++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/gnu/packages/gcc.scm b/gnu/packages/gcc.scm index 1db37529f7..1b444c2b02 100644 --- a/gnu/packages/gcc.scm +++ b/gnu/packages/gcc.scm @@ -1156,34 +1156,34 @@ (define (make-gccgo gcc) (arguments (substitute-keyword-arguments (package-arguments gccgo) ((#:phases phases) - `(modify-phases ,phases - (add-after 'install 'wrap-go-with-tool-path - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (exedir (string-append out "/libexec/gcc")) - (tooldir (dirname (car (find-files exedir "^cgo$"))))) - (wrap-program (string-append out "/bin/go") - `("GCCGOTOOLDIR" = - (,(string-append "${GCCGOTOOLDIR:-" tooldir "}"))) - `("GOROOT" = - (,(string-append "${GOROOT:-" out "}"))))))) - (add-before 'configure 'fix-gotools-runpath - (lambda _ - (substitute* "gotools/Makefile.in" - (("AM_LDFLAGS =" all) - (string-append all " -Wl,-rpath=$(libdir) "))))) - (add-before 'configure 'remove-tool-reference-from-libgo - (lambda _ - (substitute* "libgo/Makefile.in" - (("(GccgoToolDir = \\\")[^\\\"]+" _ start) - (string-append start "/nonexistent")) - ,@(if (version>=? (package-version gccgo) "12.0") - '((("(defaultGOROOT = `)[^`]+" _ start) - (string-append start "/nonexistent"))) - '((("(DefaultGoroot = \\\")[^\\\"]+" _ start) - (string-append start "/nonexistent")))) - (("(defaultGOROOTValue.*?return `)[^`]+" _ start) - (string-append start "/nonexistent")))))))))))) + #~(modify-phases #$phases + (add-after 'install 'wrap-go-with-tool-path + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (exedir (string-append out "/libexec/gcc")) + (tooldir (dirname (car (find-files exedir "^cgo$"))))) + (wrap-program (string-append out "/bin/go") + `("GCCGOTOOLDIR" = + (,(string-append "${GCCGOTOOLDIR:-" tooldir "}"))) + `("GOROOT" = + (,(string-append "${GOROOT:-" out "}"))))))) + (add-before 'configure 'fix-gotools-runpath + (lambda _ + (substitute* "gotools/Makefile.in" + (("AM_LDFLAGS =" all) + (string-append all " -Wl,-rpath=$(libdir) "))))) + (add-before 'configure 'remove-tool-reference-from-libgo + (lambda _ + (substitute* "libgo/Makefile.in" + (("(GccgoToolDir = \\\")[^\\\"]+" _ start) + (string-append start "/nonexistent")) + #$@(if (version>=? (package-version gccgo) "12.0") + '((("(defaultGOROOT = `)[^`]+" _ start) + (string-append start "/nonexistent"))) + '((("(DefaultGoroot = \\\")[^\\\"]+" _ start) + (string-append start "/nonexistent")))) + (("(defaultGOROOTValue.*?return `)[^`]+" _ start) + (string-append start "/nonexistent")))))))))))) (define-public gccgo-4.9 (custom-gcc (package