[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
05/12: bootstrap: static-bash-for-glibc: Consider %current-system at run
From: |
Jan Nieuwenhuizen |
Subject: |
05/12: bootstrap: static-bash-for-glibc: Consider %current-system at run time. |
Date: |
Tue, 18 Sep 2018 16:40:37 -0400 (EDT) |
janneke pushed a commit to branch wip-bootstrap
in repository guix.
commit 22625dc8b94b918b2cf7abd5a1301d4679ab245e
Author: Jan Nieuwenhuizen <address@hidden>
Date: Tue Sep 18 22:25:27 2018 +0200
bootstrap: static-bash-for-glibc: Consider %current-system at run time.
* gnu/packages/commencement.scm (static-bash-for-glibc): Rewrite so
that (%boot1-inputs) is evaluated run time, rather than at load time.
---
gnu/packages/commencement.scm | 54 ++++++++++++++++++++++---------------------
1 file changed, 28 insertions(+), 26 deletions(-)
diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index 8c47469..c8ab83c 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -634,33 +634,35 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a/~a
\"address@hidden"~%"
(define static-bash-for-glibc
;; A statically-linked Bash to be used by GLIBC-FINAL in system(3) & co.
- (let* ((gcc (cross-gcc-wrapper gcc-boot0 binutils-boot0
- glibc-final-with-bootstrap-bash
- (car (assoc-ref (%boot1-inputs) "bash"))))
- (bash (package
- (inherit static-bash)
- (arguments
- (substitute-keyword-arguments
- (package-arguments static-bash)
- ((#:guile _ #f)
- '%bootstrap-guile)
- ((#:configure-flags flags '())
- ;; Add a '-L' flag so that the pseudo-cross-ld of
- ;; BINUTILS-BOOT0 can find libc.a.
- `(append ,flags
- (list (string-append "LDFLAGS=-static -L"
- (assoc-ref %build-inputs
- "libc:static")
- "/lib"))))))))
- (inputs `(("gcc" ,gcc)
- ("libc" ,glibc-final-with-bootstrap-bash)
- ("libc:static" ,glibc-final-with-bootstrap-bash "static")
- ,@(fold alist-delete (%boot1-inputs)
- '("gcc" "libc")))))
+ (let ((bash (package
+ (inherit static-bash)
+ (arguments
+ (substitute-keyword-arguments
+ (package-arguments static-bash)
+ ((#:guile _ #f)
+ '%bootstrap-guile)
+ ((#:configure-flags flags '())
+ ;; Add a '-L' flag so that the pseudo-cross-ld of
+ ;; BINUTILS-BOOT0 can find libc.a.
+ `(append ,flags
+ (list (string-append "LDFLAGS=-static -L"
+ (assoc-ref %build-inputs
+ "libc:static")
+ "/lib")))))))))
(package-with-bootstrap-guile
- (package-with-explicit-inputs bash (lambda _ inputs)
- (current-source-location)
- #:guile %bootstrap-guile))))
+ (package-with-explicit-inputs
+ bash
+ (lambda _
+ (let ((gcc (cross-gcc-wrapper gcc-boot0 binutils-boot0
+ glibc-final-with-bootstrap-bash
+ (car (assoc-ref (%boot1-inputs)
"bash")))))
+ `(("gcc" ,gcc)
+ ("libc" ,glibc-final-with-bootstrap-bash)
+ ("libc:static" ,glibc-final-with-bootstrap-bash "static")
+ ,@(fold alist-delete (%boot1-inputs)
+ '("gcc" "libc")))))
+ (current-source-location)
+ #:guile %bootstrap-guile))))
(define gettext-boot0
;; A minimal gettext used during bootstrap.
- branch wip-bootstrap created (now 6d975c9), Jan Nieuwenhuizen, 2018/09/18
- 03/12: gnu: m4-boot0: New variable., Jan Nieuwenhuizen, 2018/09/18
- 02/12: bootstrap: %bootstrap-inputs+toolchain: Replace %bootstrap-inputs., Jan Nieuwenhuizen, 2018/09/18
- 05/12: bootstrap: static-bash-for-glibc: Consider %current-system at run time.,
Jan Nieuwenhuizen <=
- 06/12: guix: package-from-tarball: Allow PROGRAM-TO-TEST to be #f., Jan Nieuwenhuizen, 2018/09/18
- 08/12: gnu: Add linux-libre-headers-bootstrap-tarball., Jan Nieuwenhuizen, 2018/09/18
- 01/12: bootstrap: %bootstrap-inputs: Wrap input lists into thunks., Jan Nieuwenhuizen, 2018/09/18
- 04/12: bootstrap: Use thunk for inputs in package-with-explicit-inputs., Jan Nieuwenhuizen, 2018/09/18
- 09/12: bootstrap: Add Mes bootstrap seeds., Jan Nieuwenhuizen, 2018/09/18
- 11/12: bootstrap: Replace GNU toolchain seeds with Mes for i686-linux., Jan Nieuwenhuizen, 2018/09/18
- 07/12: guix: copy-linux-headers: Extract procedure, add headers., Jan Nieuwenhuizen, 2018/09/18
- 12/12: doc: Describe the Reduced Binary Seed bootstrap., Jan Nieuwenhuizen, 2018/09/18
- 10/12: bootstrap: Add Mes bootstrap., Jan Nieuwenhuizen, 2018/09/18