diff options
| author | Ludovic Courtès <ludo@gnu.org> | 2024-08-14 17:51:48 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2024-08-31 10:45:45 +0200 |
| commit | e8a1b10c272794f8380c4ddc221797c10b1f7cb2 (patch) | |
| tree | 5f51ad2a406a05f1ada615fea27e9f11489b5d36 /gnu/packages/make-bootstrap.scm | |
| parent | cfd67d36b53f920a43efe3716a1d670127310a27 (diff) | |
gnu: make-bootstrap: Fix cross-compilation of ‘%glibc-stripped’.
Previously, ‘guix build bootstrap-tarballs --target=aarch64-linux-gnu’
or similar would construct a cross-libc where ‘%current-target-system’
is set. This would lead to a failure in the
‘add-cross-binutils-to-PATH’ phase, which assumes that
‘%current-target-system’ is #f; indeed, ‘cross-libc’ already returns a
cross libc and so ‘%current-target-system’ must be set to #f.
* gnu/packages/make-bootstrap.scm (%glibc-stripped)[inputs]: Move libc to…
[native-inputs]: … here.
Change-Id: Ifbf5e519ba3198940f4de4a36075d5302e923172
Diffstat (limited to 'gnu/packages/make-bootstrap.scm')
| -rw-r--r-- | gnu/packages/make-bootstrap.scm | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/gnu/packages/make-bootstrap.scm b/gnu/packages/make-bootstrap.scm index d5b6b818b38..679aa46d605 100644 --- a/gnu/packages/make-bootstrap.scm +++ b/gnu/packages/make-bootstrap.scm | |||
| @@ -448,19 +448,20 @@ for `sh' in $PATH, and without nscd, and with static NSS modules." | |||
| 448 | (make-stripped-libc (assoc-ref %outputs "out") | 448 | (make-stripped-libc (assoc-ref %outputs "out") |
| 449 | (assoc-ref %build-inputs "libc") | 449 | (assoc-ref %build-inputs "libc") |
| 450 | (assoc-ref %build-inputs "kernel-headers"))))) | 450 | (assoc-ref %build-inputs "kernel-headers"))))) |
| 451 | (inputs `(("kernel-headers" | 451 | (native-inputs |
| 452 | ,(if (or (and (%current-target-system) | 452 | `(("libc" ,(let ((target (%current-target-system))) |
| 453 | (target-hurd? (%current-target-system))) | 453 | (if target |
| 454 | (string-suffix? "-hurd" (%current-system))) | 454 | (glibc-for-bootstrap |
| 455 | gnumach-headers | 455 | (parameterize ((%current-target-system #f)) |
| 456 | linux-libre-headers)) | 456 | (cross-libc target))) |
| 457 | ("libc" ,(let ((target (%current-target-system))) | 457 | glibc))))) |
| 458 | (if target | 458 | (inputs |
| 459 | (glibc-for-bootstrap | 459 | `(("kernel-headers" |
| 460 | (parameterize ((%current-target-system #f)) | 460 | ,(if (or (and (%current-target-system) |
| 461 | (cross-libc target))) | 461 | (target-hurd? (%current-target-system))) |
| 462 | glibc))))) | 462 | (string-suffix? "-hurd" (%current-system))) |
| 463 | (native-inputs '()) | 463 | gnumach-headers |
| 464 | linux-libre-headers)))) | ||
| 464 | (propagated-inputs '()) | 465 | (propagated-inputs '()) |
| 465 | 466 | ||
| 466 | ;; Only one output. | 467 | ;; Only one output. |
