From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:35742) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jT8PH-0001p4-1P for guix-patches@gnu.org; Mon, 27 Apr 2020 14:23:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jT8PG-00037K-H0 for guix-patches@gnu.org; Mon, 27 Apr 2020 14:23:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54793) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jT8PG-00037F-2j for guix-patches@gnu.org; Mon, 27 Apr 2020 14:23:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jT8PF-0004Zr-VA for guix-patches@gnu.org; Mon, 27 Apr 2020 14:23:01 -0400 Subject: [bug#40908] [PATCH core-updates 2/5] gnu: %guile-static-stripped: Rewrite in terms of 'make-guile-static-stripped'. Resent-Message-ID: From: Marius Bakke Date: Mon, 27 Apr 2020 20:22:19 +0200 Message-Id: <20200427182222.28142-2-mbakke@fastmail.com> In-Reply-To: <20200427182222.28142-1-mbakke@fastmail.com> References: <20200427182222.28142-1-mbakke@fastmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 40908@debbugs.gnu.org The derivation changes slightly, but the end result is bit-identical. * gnu/packages/make-bootstrap.scm (make-guile-static-stripped): New procedure. (%guile-static-stripped): Adjust accordingly. --- gnu/packages/make-bootstrap.scm | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/gnu/packages/make-bootstrap.scm b/gnu/packages/make-bootstrap.scm index f4d7fd6a2a..d336818299 100644 --- a/gnu/packages/make-bootstrap.scm +++ b/gnu/packages/make-bootstrap.scm @@ -745,30 +745,30 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." "guile-default-utf8.patch" "guile-linux-syscalls.patch"))) -(define %guile-static-stripped - ;; A stripped static Guile binary, for use during bootstrap. - (package (inherit %guile-static) - (name "guile-static-stripped") +(define* (make-guile-static-stripped static-guile) + (package + (inherit static-guile) + (name (string-append (package-name static-guile) "-stripped")) (build-system trivial-build-system) (arguments ;; The end result should depend on nothing but itself. `(#:allowed-references ("out") #:modules ((guix build utils)) #:builder - (let () + (let ((version ,(version-major+minor (package-version static-guile)))) (use-modules (guix build utils)) (let* ((in (assoc-ref %build-inputs "guile")) (out (assoc-ref %outputs "out")) (guile1 (string-append in "/bin/guile")) (guile2 (string-append out "/bin/guile"))) - (mkdir-p (string-append out "/share/guile/2.0")) - (copy-recursively (string-append in "/share/guile/2.0") - (string-append out "/share/guile/2.0")) + (mkdir-p (string-append out "/share/guile/" version)) + (copy-recursively (string-append in "/share/guile/" version) + (string-append out "/share/guile/" version)) - (mkdir-p (string-append out "/lib/guile/2.0/ccache")) - (copy-recursively (string-append in "/lib/guile/2.0/ccache") - (string-append out "/lib/guile/2.0/ccache")) + (mkdir-p (string-append out "/lib/guile/" version "/ccache")) + (copy-recursively (string-append in "/lib/guile/" version "/ccache") + (string-append out "/lib/guile/" version "/ccache")) (mkdir (string-append out "/bin")) (copy-file guile1 guile2) @@ -789,10 +789,14 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." '((invoke guile2 "--version"))) #t)))) - (inputs `(("guile" ,%guile-static))) + (inputs `(("guile" ,static-guile))) (outputs '("out")) (synopsis "Minimal statically-linked and relocatable Guile"))) +(define %guile-static-stripped + ;; A stripped static Guile binary, for use during bootstrap. + (make-guile-static-stripped %guile-static)) + (define (tarball-package pkg) "Return a package containing a tarball of PKG." (package (inherit pkg) -- 2.26.2