summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJanneke Nieuwenhuizen <janneke@gnu.org>2024-12-05 20:54:58 +0100
committerAndreas Enge <andreas@enge.fr>2025-07-18 20:17:01 +0200
commite50f470fe6f66f48e7a5c8b7174f24aad6d9999b (patch)
tree6db4c23fc9ab521e21c3be53e5e922431be003f6
parent01e522d008bff1191b2656cd8bbabdced42e0e4d (diff)
Revert "Partial revert "gnu: bootstrap: %bootstrap-gcc: Also wrap g++ for the 64bit Hurd.""
This cleanup was reverted because it led to a world rebuild. This reverts commit 006679d1e6ca7acea0629b4f019c8cf89cde08be. Change-Id: Id14fcc35fb8d550644b4d6cebace110ae0bab59e
-rw-r--r--gnu/packages/bootstrap.scm59
1 files changed, 23 insertions, 36 deletions
diff --git a/gnu/packages/bootstrap.scm b/gnu/packages/bootstrap.scm
index 79ef8a5f41..15d8c758c6 100644
--- a/gnu/packages/bootstrap.scm
+++ b/gnu/packages/bootstrap.scm
@@ -778,14 +778,14 @@ $out/bin/guile --version~%"
(chmod "lib" #o755)
;; Patch linker scripts so they refer to the right file-names.
- ,@(if (target-hurd64?)
- '((substitute* '("lib/libc.so" "lib/libm.so")
- (("/[^ ]+/lib/(libc|libm|libh|ld)" _ prefix)
- (string-append out "/lib/" prefix))))
- '((substitute* "lib/libc.so"
- (("/[^ ]+/lib/(libc|ld)" _ prefix)
- (string-append out "/lib/" prefix)))
- #t))))))))
+ ,(if (target-hurd64?)
+ '(substitute* '("lib/libc.so" "lib/libm.so")
+ (("/[^ ]+/lib/(libc|libm|libh|ld)" _ prefix)
+ (string-append out "/lib/" prefix)))
+ '(substitute* "lib/libc.so"
+ (("/[^ ]+/lib/(libc|ld)" _ prefix)
+ (string-append out "/lib/" prefix))))
+ #t))))))
(inputs
`(("tar" ,(bootstrap-executable "tar" (%current-system)))
("xz" ,(bootstrap-executable "xz" (%current-system)))
@@ -877,22 +877,20 @@ $out/bin/guile --version~%"
(let ((builddir (getcwd))
(bindir (string-append out "/bin")))
- ,@(if (target-hurd64?)
- `((define (wrap-program program)
- (let ((wrapped (format #f ".~a-wrapped" program)))
- (rename-file program wrapped)
- (call-with-output-file program
- (lambda (p)
- (format p "#!~a
+ (define (wrap-program program)
+ (let ((wrapped (format #f ".~a-wrapped" program)))
+ (rename-file program wrapped)
+ (call-with-output-file program
+ (lambda (p)
+ (format p "#!~a
exec ~a/bin/~a -B~a/lib \
-Wl,-rpath -Wl,~a/lib \
-Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%"
- bash
- out wrapped
- libc libc libc
- ,(glibc-dynamic-linker)))))
- (chmod program #o555)))
- '())
+ bash
+ out wrapped
+ libc libc libc
+ ,(glibc-dynamic-linker)))))
+ (chmod program #o555))
(with-directory-excursion out
(invoke tar "xvf"
@@ -900,21 +898,10 @@ exec ~a/bin/~a -B~a/lib \
(with-directory-excursion bindir
(chmod "." #o755)
- ,@(if (target-hurd64?)
- `((for-each wrap-program '("gcc" "g++")))
- `((rename-file "gcc" ".gcc-wrapped")
- (call-with-output-file "gcc"
- (lambda (p)
- (format p "#!~a
-exec ~a/bin/.gcc-wrapped -B~a/lib \
- -Wl,-rpath -Wl,~a/lib \
- -Wl,-dynamic-linker -Wl,~a/~a \"$@\"~%"
- bash
- out libc libc libc
- ,(glibc-dynamic-linker))))
-
- (chmod "gcc" #o555)
- #t))))))))
+ (for-each wrap-program
+ ,(if (target-hurd64?)
+ ''("gcc" "g++")
+ ''("gcc")))))))))
(inputs
`(("tar" ,(bootstrap-executable "tar" (%current-system)))
("xz" ,(bootstrap-executable "xz" (%current-system)))