nongnu: corrupt-linux: Rewrite to use customize-linux.

This simplifies our linux package definitions to not need hash updates as they
simply follow from the inherited part of the source field. The newly added
'customize-linux' procedure from Guix is the preferred way to customize the
kernel as well.

* nongnu/packages/linux.scm (corrupt-linux): No longer take 'version' or
'hash' arguments. Inherit from 'customize-linux' as a starting package. Remove
patch for now removed 'build-doc' phase.
(linux-6.0, linux-5.15, linux-5.10, linux-5.4, linux4.19, linux-4.14,
linux-4.9, linux-arm64-generic-6.0, linux-arm64-generic-5.15): Remove version
and hash strings.
This commit is contained in:
John Kehayias 2022-12-12 20:59:44 -05:00
parent e95e2b573c
commit 3d53be2c5c
No known key found for this signature in database
GPG Key ID: 499097AE5EA815D9

View File

@ -55,69 +55,52 @@
(list (string-append "https://www.kernel.org/pub/linux/kernel/v" (list (string-append "https://www.kernel.org/pub/linux/kernel/v"
(version-major version) ".x/linux-" version ".tar.xz"))) (version-major version) ".x/linux-" version ".tar.xz")))
(define* (corrupt-linux freedo version hash #:key (name "linux")) (define* (corrupt-linux freedo #:key (name "linux"))
(package (package
(inherit freedo) (inherit
(name name) (customize-linux
(version version) #:name name
(source (origin #:source (origin (inherit (package-source freedo))
(method url-fetch) (method url-fetch)
(uri (linux-urls version)) (uri (linux-urls (package-version freedo)))
(sha256 (base32 hash)) (patches '()))))
;; By default the linux-libre package will "make infodocs" for (version (package-version freedo))
;; supported kernels (version > 5.10) which needs the following (home-page "https://www.kernel.org/")
;; patch. Include the patch if it applies rather than disabling (synopsis "Linux kernel with nonfree binary blobs included")
;; the associated "build-doc" phase. (description
(patches (if ((@@ (gnu packages linux) doc-supported?) version) "The unmodified Linux kernel, including nonfree blobs, for running Guix
(search-patches "linux-libre-infodocs-target.patch")
'()))))
(home-page "https://www.kernel.org/")
(synopsis "Linux kernel with nonfree binary blobs included")
(description
"The unmodified Linux kernel, including nonfree blobs, for running Guix
System on hardware which requires nonfree software to function."))) System on hardware which requires nonfree software to function.")))
(define-public linux-6.0 (define-public linux-6.0
(corrupt-linux linux-libre-6.0 "6.0.12" (corrupt-linux linux-libre-6.0))
"00ag63lnxw2gijw3b6v29lhrlv480m12954q5zh4jawlz3nk1dw9"))
(define-public linux-5.15 (define-public linux-5.15
(corrupt-linux linux-libre-5.15 "5.15.82" (corrupt-linux linux-libre-5.15))
"0r8v7113favmch2x6br7jk6idihza99l9qyd7ik99i5sg6xzdvpw"))
(define-public linux-5.10 (define-public linux-5.10
(corrupt-linux linux-libre-5.10 "5.10.158" (corrupt-linux linux-libre-5.10))
"1rq7lyp41fydybs53rcdjhiy271arh95xch16s5s3jhhanxj82hy"))
(define-public linux-5.4 (define-public linux-5.4
(corrupt-linux linux-libre-5.4 "5.4.224" (corrupt-linux linux-libre-5.4))
"0dixs4w7nmkjgxv9dxgjdy8v6r4parkpqyvdfyr0wqk0amdz4zcb"))
(define-public linux-4.19 (define-public linux-4.19
(corrupt-linux linux-libre-4.19 "4.19.265" (corrupt-linux linux-libre-4.19))
"1l5cdpgng1gci1p1gdr2jzqw486h3w56gpyc7fbq74hlc6nnwh1p"))
(define-public linux-4.14 (define-public linux-4.14
(corrupt-linux linux-libre-4.14 "4.14.299" (corrupt-linux linux-libre-4.14))
"0p5ic2mrb9vl3qkzvqxhia3kygjv8xa6s1kqkwgd6b4rmq1kc8r6"))
(define-public linux-4.9 (define-public linux-4.9
(corrupt-linux linux-libre-4.9 "4.9.333" (corrupt-linux linux-libre-4.9))
"0ash877gkrrc063h6ncl9d4gzyhndanpxsdgf1a93abbfv281gs1"))
(define-public linux linux-6.0) (define-public linux linux-6.0)
;; linux-lts points to the *newest* released long-term support version. ;; linux-lts points to the *newest* released long-term support version.
(define-public linux-lts linux-5.15) (define-public linux-lts linux-5.15)
(define-public linux-arm64-generic-6.0 (define-public linux-arm64-generic-6.0
(corrupt-linux linux-libre-arm64-generic "6.0.9" (corrupt-linux linux-libre-arm64-generic #:name "linux-arm64-generic"))
"1irip1yk62carcisxlacwcxsiqib4qswx6h5mfhv8f97x04a4531"
#:name "linux-arm64-generic"))
(define-public linux-arm64-generic-5.15 (define-public linux-arm64-generic-5.15
(corrupt-linux linux-libre-arm64-generic "5.15.79" (corrupt-linux linux-libre-arm64-generic #:name "linux-arm64-generic"))
"0m61k7k6lj24z9a266q08wzghggjik2wizcabdwd1vn0vcqr18yb"
#:name "linux-arm64-generic"))
(define-public linux-arm64-generic linux-arm64-generic-6.0) (define-public linux-arm64-generic linux-arm64-generic-6.0)