mirror of
git://git.savannah.gnu.org/guix.git
synced 2023-12-14 03:33:07 +01:00
gnu: glibc: Make sure the bootstrap libc is not in $CPATH.
This fixes a bug whereby the bootstrap-glibc headers could be picked up when building libc.so, which could be noticed by the fact that the .debug files contained references to bootstrap-glibc. * gnu/packages/base.scm (glibc-final-with-bootstrap-bash)[arguments]: Add 'pre-configure' phase. [inputs]: Remove 'alist-delete' call.
This commit is contained in:
parent
3d78d51d8e
commit
1c93be5600
1 changed files with 22 additions and 7 deletions
|
@ -827,22 +827,37 @@ identifier SYSTEM."
|
||||||
;; Build Sun/ONC RPC support. In particular,
|
;; Build Sun/ONC RPC support. In particular,
|
||||||
;; install rpc/*.h.
|
;; install rpc/*.h.
|
||||||
"--enable-obsolete-rpc")
|
"--enable-obsolete-rpc")
|
||||||
,flags)))))
|
,flags))
|
||||||
|
((#:phases phases)
|
||||||
|
`(alist-cons-before
|
||||||
|
'configure 'pre-configure
|
||||||
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
|
;; Don't clobber CPATH with the bootstrap libc.
|
||||||
|
(setenv "NATIVE_CPATH" (getenv "CPATH"))
|
||||||
|
(unsetenv "CPATH")
|
||||||
|
|
||||||
|
;; 'rpcgen' needs native libc headers to be built.
|
||||||
|
(substitute* "sunrpc/Makefile"
|
||||||
|
(("sunrpc-CPPFLAGS =.*" all)
|
||||||
|
(string-append "CPATH = $(NATIVE_CPATH)\n"
|
||||||
|
"export CPATH\n"
|
||||||
|
all "\n"))))
|
||||||
|
,phases)))))
|
||||||
(propagated-inputs `(("linux-headers" ,(linux-libre-headers-boot0))))
|
(propagated-inputs `(("linux-headers" ,(linux-libre-headers-boot0))))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("texinfo" ,texinfo-boot0)
|
`(("texinfo" ,texinfo-boot0)
|
||||||
("perl" ,perl-boot0)))
|
("perl" ,perl-boot0)))
|
||||||
(inputs
|
(inputs
|
||||||
`( ;; A native GCC is needed to build `cross-rpcgen'.
|
`(;; The boot inputs. That includes the bootstrap libc. We don't want
|
||||||
|
;; it in $CPATH, hence the 'pre-configure' phase above.
|
||||||
|
,@%boot1-inputs
|
||||||
|
|
||||||
|
;; A native GCC is needed to build `cross-rpcgen'.
|
||||||
("native-gcc" ,@(assoc-ref %boot0-inputs "gcc"))
|
("native-gcc" ,@(assoc-ref %boot0-inputs "gcc"))
|
||||||
|
|
||||||
;; Here, we use the bootstrap Bash, which is not satisfactory
|
;; Here, we use the bootstrap Bash, which is not satisfactory
|
||||||
;; because we don't want to depend on bootstrap tools.
|
;; because we don't want to depend on bootstrap tools.
|
||||||
("static-bash" ,@(assoc-ref %boot0-inputs "bash"))
|
("static-bash" ,@(assoc-ref %boot0-inputs "bash")))))))
|
||||||
|
|
||||||
,@%boot1-inputs
|
|
||||||
,@(alist-delete "static-bash"
|
|
||||||
(package-inputs glibc))))))) ; patches
|
|
||||||
|
|
||||||
(define (cross-gcc-wrapper gcc binutils glibc bash)
|
(define (cross-gcc-wrapper gcc binutils glibc bash)
|
||||||
"Return a wrapper for the pseudo-cross toolchain GCC/BINUTILS/GLIBC
|
"Return a wrapper for the pseudo-cross toolchain GCC/BINUTILS/GLIBC
|
||||||
|
|
Loading…
Reference in a new issue