gnu: cross-base: Update phase style.
* gnu/packages/cross-base.scm (cross-kernel-headers, cross-libc): Use MODIFY-PHASES syntax and end phases with #t.
This commit is contained in:
parent
fc783fb264
commit
273cab96d7
1 changed files with 37 additions and 37 deletions
|
@ -3,6 +3,7 @@
|
||||||
;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
|
;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
|
||||||
;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
|
;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
|
||||||
;;; Copyright © 2016 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
|
;;; Copyright © 2016 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
|
||||||
|
;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of GNU Guix.
|
;;; This file is part of GNU Guix.
|
||||||
;;;
|
;;;
|
||||||
|
@ -314,14 +315,14 @@ target that libc."
|
||||||
`(#:modules ((guix build gnu-build-system)
|
`(#:modules ((guix build gnu-build-system)
|
||||||
(guix build utils)
|
(guix build utils)
|
||||||
(srfi srfi-26))
|
(srfi srfi-26))
|
||||||
#:phases (alist-cons-before
|
#:phases (modify-phases %standard-phases
|
||||||
'configure 'set-cross-headers-path
|
(add-before 'configure 'set-cross-headers-path
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(let* ((mach (assoc-ref inputs "cross-gnumach-headers"))
|
(let* ((mach (assoc-ref inputs "cross-gnumach-headers"))
|
||||||
(cpath (string-append mach "/include")))
|
(cpath (string-append mach "/include")))
|
||||||
(for-each (cut setenv <> cpath)
|
(for-each (cut setenv <> cpath)
|
||||||
',%gcc-cross-include-paths)))
|
',%gcc-cross-include-paths)
|
||||||
%standard-phases)
|
#t))))
|
||||||
#:configure-flags (list ,(string-append "--target=" target))
|
#:configure-flags (list ,(string-append "--target=" target))
|
||||||
,@(package-arguments mig)))
|
,@(package-arguments mig)))
|
||||||
|
|
||||||
|
@ -352,16 +353,16 @@ target that libc."
|
||||||
(srfi srfi-26))
|
(srfi srfi-26))
|
||||||
,@(package-arguments glibc/hurd-headers))
|
,@(package-arguments glibc/hurd-headers))
|
||||||
((#:phases phases)
|
((#:phases phases)
|
||||||
`(alist-cons-before
|
`(modify-phases ,phases
|
||||||
'pre-configure 'set-cross-headers-path
|
(add-before 'pre-configure 'set-cross-headers-path
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(let* ((mach (assoc-ref inputs "gnumach-headers"))
|
(let* ((mach (assoc-ref inputs "gnumach-headers"))
|
||||||
(hurd (assoc-ref inputs "hurd-headers"))
|
(hurd (assoc-ref inputs "hurd-headers"))
|
||||||
(cpath (string-append mach "/include:"
|
(cpath (string-append mach "/include:"
|
||||||
hurd "/include")))
|
hurd "/include")))
|
||||||
(for-each (cut setenv <> cpath)
|
(for-each (cut setenv <> cpath)
|
||||||
',%gcc-cross-include-paths)))
|
',%gcc-cross-include-paths)
|
||||||
,phases))))
|
#t)))))))
|
||||||
|
|
||||||
(propagated-inputs `(("gnumach-headers" ,xgnumach-headers)
|
(propagated-inputs `(("gnumach-headers" ,xgnumach-headers)
|
||||||
("hurd-headers" ,xhurd-headers)))
|
("hurd-headers" ,xhurd-headers)))
|
||||||
|
@ -382,14 +383,14 @@ target that libc."
|
||||||
(srfi srfi-26))
|
(srfi srfi-26))
|
||||||
,@(package-arguments hurd-minimal))
|
,@(package-arguments hurd-minimal))
|
||||||
((#:phases phases)
|
((#:phases phases)
|
||||||
`(alist-cons-before
|
`(modify-phases ,phases
|
||||||
'configure 'set-cross-headers-path
|
(add-before 'configure 'set-cross-headers-path
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(let* ((glibc-headers (assoc-ref inputs "cross-glibc-hurd-headers"))
|
(let* ((glibc-headers (assoc-ref inputs "cross-glibc-hurd-headers"))
|
||||||
(cpath (string-append glibc-headers "/include")))
|
(cpath (string-append glibc-headers "/include")))
|
||||||
(for-each (cut setenv <> cpath)
|
(for-each (cut setenv <> cpath)
|
||||||
',%gcc-cross-include-paths)))
|
',%gcc-cross-include-paths)
|
||||||
,phases))))
|
#t)))))))
|
||||||
|
|
||||||
(inputs `(("cross-glibc-hurd-headers" ,xglibc/hurd-headers)))
|
(inputs `(("cross-glibc-hurd-headers" ,xglibc/hurd-headers)))
|
||||||
|
|
||||||
|
@ -456,17 +457,16 @@ XBINUTILS and the cross tool chain."
|
||||||
`(cons ,(string-append "--host=" target)
|
`(cons ,(string-append "--host=" target)
|
||||||
,flags))
|
,flags))
|
||||||
((#:phases phases)
|
((#:phases phases)
|
||||||
`(alist-cons-before
|
`(modify-phases ,phases
|
||||||
'configure 'set-cross-kernel-headers-path
|
(add-before 'configure 'set-cross-kernel-headers-path
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(let* ((kernel (assoc-ref inputs "kernel-headers"))
|
(let* ((kernel (assoc-ref inputs "kernel-headers"))
|
||||||
(cpath (string-append kernel "/include")))
|
(cpath (string-append kernel "/include")))
|
||||||
(for-each (cut setenv <> cpath)
|
(for-each (cut setenv <> cpath)
|
||||||
',%gcc-cross-include-paths)
|
',%gcc-cross-include-paths)
|
||||||
(setenv "CROSS_LIBRARY_PATH"
|
(setenv "CROSS_LIBRARY_PATH"
|
||||||
(string-append kernel "/lib")) ;for Hurd's libihash
|
(string-append kernel "/lib")) ; for Hurd's libihash
|
||||||
#t))
|
#t)))))))
|
||||||
,phases))))
|
|
||||||
|
|
||||||
;; Shadow the native "kernel-headers" because glibc's recipe expects the
|
;; Shadow the native "kernel-headers" because glibc's recipe expects the
|
||||||
;; "kernel-headers" input to point to the right thing.
|
;; "kernel-headers" input to point to the right thing.
|
||||||
|
|
Reference in a new issue