mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
gnu: linux-libre-headers: Use modify-phases.
* gnu/packages/linux.scm (linux-libre-headers): Use modify phases.
This commit is contained in:
parent
b14a838509
commit
b450d2b440
1 changed files with 28 additions and 30 deletions
|
@ -109,17 +109,36 @@
|
||||||
version "-gnu.tar.xz")))
|
version "-gnu.tar.xz")))
|
||||||
|
|
||||||
(define-public linux-libre-headers
|
(define-public linux-libre-headers
|
||||||
(let* ((version "4.4.18")
|
(package
|
||||||
(build-phase
|
(name "linux-libre-headers")
|
||||||
(lambda (arch)
|
(version "4.4.18")
|
||||||
`(lambda _
|
(source (origin
|
||||||
(setenv "ARCH" ,(system->linux-architecture arch))
|
(method url-fetch)
|
||||||
|
(uri (linux-libre-urls version))
|
||||||
|
(sha256
|
||||||
|
(base32
|
||||||
|
"0k8k17in7dkjd9d8zg3i8l1ax466dba6bxw28flxizzyq8znljps"))))
|
||||||
|
(build-system gnu-build-system)
|
||||||
|
(native-inputs `(("perl" ,perl)))
|
||||||
|
(arguments
|
||||||
|
`(#:modules ((guix build gnu-build-system)
|
||||||
|
(guix build utils)
|
||||||
|
(srfi srfi-1))
|
||||||
|
#:phases
|
||||||
|
(modify-phases %standard-phases
|
||||||
|
(delete 'configure)
|
||||||
|
(replace 'build
|
||||||
|
(lambda _
|
||||||
|
(let ((arch ,(system->linux-architecture
|
||||||
|
(or (%current-target-system)
|
||||||
|
(%current-system)))))
|
||||||
|
(setenv "ARCH" arch)
|
||||||
(format #t "`ARCH' set to `~a'~%" (getenv "ARCH"))
|
(format #t "`ARCH' set to `~a'~%" (getenv "ARCH"))
|
||||||
|
|
||||||
(and (zero? (system* "make" "defconfig"))
|
(and (zero? (system* "make" "defconfig"))
|
||||||
(zero? (system* "make" "mrproper" "headers_check"))))))
|
(zero? (system* "make" "mrproper" "headers_check"))))))
|
||||||
(install-phase
|
(replace 'install
|
||||||
`(lambda* (#:key outputs #:allow-other-keys)
|
(lambda* (#:key outputs #:allow-other-keys)
|
||||||
(let ((out (assoc-ref outputs "out")))
|
(let ((out (assoc-ref outputs "out")))
|
||||||
(and (zero? (system* "make"
|
(and (zero? (system* "make"
|
||||||
(string-append "INSTALL_HDR_PATH=" out)
|
(string-append "INSTALL_HDR_PATH=" out)
|
||||||
|
@ -139,33 +158,12 @@
|
||||||
(for-each delete-file (find-files out "\\.install"))
|
(for-each delete-file (find-files out "\\.install"))
|
||||||
|
|
||||||
#t))))))
|
#t))))))
|
||||||
(package
|
|
||||||
(name "linux-libre-headers")
|
|
||||||
(version version)
|
|
||||||
(source (origin
|
|
||||||
(method url-fetch)
|
|
||||||
(uri (linux-libre-urls version))
|
|
||||||
(sha256
|
|
||||||
(base32
|
|
||||||
"0k8k17in7dkjd9d8zg3i8l1ax466dba6bxw28flxizzyq8znljps"))))
|
|
||||||
(build-system gnu-build-system)
|
|
||||||
(native-inputs `(("perl" ,perl)))
|
|
||||||
(arguments
|
|
||||||
`(#:modules ((guix build gnu-build-system)
|
|
||||||
(guix build utils)
|
|
||||||
(srfi srfi-1))
|
|
||||||
#:phases (alist-replace
|
|
||||||
'build ,(build-phase (or (%current-target-system)
|
|
||||||
(%current-system)))
|
|
||||||
(alist-replace
|
|
||||||
'install ,install-phase
|
|
||||||
(alist-delete 'configure %standard-phases)))
|
|
||||||
#:allowed-references ()
|
#:allowed-references ()
|
||||||
#:tests? #f))
|
#:tests? #f))
|
||||||
|
(home-page "http://www.gnu.org/software/linux-libre")
|
||||||
(synopsis "GNU Linux-Libre kernel headers")
|
(synopsis "GNU Linux-Libre kernel headers")
|
||||||
(description "Headers of the Linux-Libre kernel.")
|
(description "Headers of the Linux-Libre kernel.")
|
||||||
(license license:gpl2)
|
(license license:gpl2)))
|
||||||
(home-page "http://www.gnu.org/software/linux-libre/"))))
|
|
||||||
|
|
||||||
(define-public module-init-tools
|
(define-public module-init-tools
|
||||||
(package
|
(package
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue