gnu: commencement: Update phase style.
* gnu/packages/commencement.scm (gnu-make-boot0): Substitute INVOKE for SYSTEM* and end phases with #t. (glibc-final-with-bootstrap-bash)[arguments]: Use MODIFY-PHASES syntax and end phase with #t. (gcc-boot0)[arguments]: Do all of the above.
This commit is contained in:
parent
ba81ca6af3
commit
53bfec7bc4
|
@ -4,6 +4,7 @@
|
|||
;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
|
||||
;;; Copyright © 2014, 2015, 2017 Mark H Weaver <mhw@netris.org>
|
||||
;;; Copyright © 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
|
||||
;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
|
@ -81,12 +82,14 @@
|
|||
`(modify-phases ,phases
|
||||
(replace 'build
|
||||
(lambda _
|
||||
(zero? (system* "./build.sh"))))
|
||||
(invoke "./build.sh")
|
||||
#t))
|
||||
(replace 'install
|
||||
(lambda* (#:key outputs #:allow-other-keys)
|
||||
(let* ((out (assoc-ref outputs "out"))
|
||||
(bin (string-append out "/bin")))
|
||||
(install-file "make" bin)))))))))
|
||||
(install-file "make" bin)
|
||||
#t))))))))
|
||||
(native-inputs '()) ; no need for 'pkg-config'
|
||||
(inputs %bootstrap-inputs))))
|
||||
|
||||
|
@ -253,8 +256,8 @@
|
|||
"--(with-system-zlib|enable-languages.*)" <>)
|
||||
,flags)))
|
||||
((#:phases phases)
|
||||
`(alist-cons-after
|
||||
'unpack 'unpack-gmp&co
|
||||
`(modify-phases ,phases
|
||||
(add-after 'unpack 'unpack-gmp&co
|
||||
(lambda* (#:key inputs #:allow-other-keys)
|
||||
(let ((gmp (assoc-ref %build-inputs "gmp-source"))
|
||||
(mpfr (assoc-ref %build-inputs "mpfr-source"))
|
||||
|
@ -263,9 +266,7 @@
|
|||
;; To reduce the set of pre-built bootstrap inputs, build
|
||||
;; GMP & co. from GCC.
|
||||
(for-each (lambda (source)
|
||||
(or (zero? (system* "tar" "xvf" source))
|
||||
(error "failed to unpack tarball"
|
||||
source)))
|
||||
(invoke "tar" "xvf" source))
|
||||
(list gmp mpfr mpc))
|
||||
|
||||
;; Create symlinks like `gmp' -> `gmp-x.y.z'.
|
||||
|
@ -276,9 +277,9 @@
|
|||
(package-full-name lib)
|
||||
char-set:letter)
|
||||
,(package-name lib)))
|
||||
(list gmp-6.0 mpfr mpc))))
|
||||
(alist-cons-after
|
||||
'install 'symlink-libgcc_eh
|
||||
(list gmp-6.0 mpfr mpc))
|
||||
#t)))
|
||||
(add-after 'install 'symlink-libgcc_eh
|
||||
(lambda* (#:key outputs #:allow-other-keys)
|
||||
(let ((out (assoc-ref outputs "lib")))
|
||||
;; Glibc wants to link against libgcc_eh, so provide
|
||||
|
@ -287,8 +288,8 @@
|
|||
(string-append out "/lib/gcc/"
|
||||
,(boot-triplet)
|
||||
"/" ,(package-version gcc))
|
||||
(symlink "libgcc.a" "libgcc_eh.a"))))
|
||||
,phases))))))
|
||||
(symlink "libgcc.a" "libgcc_eh.a"))
|
||||
#t))))))))
|
||||
|
||||
(inputs `(("gmp-source" ,(package-source gmp-6.0))
|
||||
("mpfr-source" ,(package-source mpfr))
|
||||
|
@ -503,8 +504,8 @@ the bootstrap environment."
|
|||
"--enable-obsolete-rpc")
|
||||
,flags))
|
||||
((#:phases phases)
|
||||
`(alist-cons-before
|
||||
'configure 'pre-configure
|
||||
`(modify-phases ,phases
|
||||
(add-before 'configure 'pre-configure
|
||||
(lambda* (#:key inputs #:allow-other-keys)
|
||||
;; Don't clobber CPATH with the bootstrap libc.
|
||||
(setenv "NATIVE_CPATH" (getenv "CPATH"))
|
||||
|
@ -524,8 +525,8 @@ the bootstrap environment."
|
|||
(("sunrpc-CPPFLAGS =.*" all)
|
||||
(string-append "CPATH = $(NATIVE_CPATH)\n"
|
||||
"export CPATH\n"
|
||||
all "\n"))))
|
||||
,phases)))))
|
||||
all "\n")))
|
||||
#t)))))))
|
||||
(propagated-inputs `(("kernel-headers" ,(kernel-headers-boot0))))
|
||||
(native-inputs
|
||||
`(("texinfo" ,texinfo-boot0)
|
||||
|
|
Loading…
Reference in New Issue