nongnu: amdgpu-firmware: Use gnu-build-system.

* nongnu/packages/linux.scm (amdgpu-firmware): Use gnu-build-system.
This commit is contained in:
Alex Griffin 2020-01-05 12:18:46 -06:00
parent 1da9083f98
commit f1bfe90179

View file

@ -114,24 +114,21 @@ if your hardware is supported by one of the smaller firmware packages.")
(package (package
(inherit linux-firmware) (inherit linux-firmware)
(name "amdgpu-firmware") (name "amdgpu-firmware")
(build-system trivial-build-system) (build-system gnu-build-system)
(arguments (arguments
`(#:modules ((guix build utils)) `(#:tests? #f
#:builder #:license-file-regexp "LICENSE.amdgpu"
(begin #:phases
(use-modules (guix build utils)) (modify-phases %standard-phases
(let* ((source (assoc-ref %build-inputs "source")) (replace 'install
(fw-dir (string-append %output "/lib/firmware/")) (lambda* (#:key outputs #:allow-other-keys)
(bin-dir (string-append fw-dir "/amdgpu")) (let* ((out (assoc-ref outputs "out"))
(gzip (assoc-ref %build-inputs "gzip")) (fw-dir (string-append out "/lib/firmware"))
(tar (assoc-ref %build-inputs "tar"))) (bin-dir (string-append fw-dir "/amdgpu")))
(set-path-environment-variable "PATH" '("bin")
(list tar gzip))
(invoke "tar" "--strip-components=1" "-xvf" source)
(mkdir-p bin-dir) (mkdir-p bin-dir)
(copy-recursively "./amdgpu" bin-dir) (copy-recursively "./amdgpu" bin-dir)
(install-file "./LICENSE.amdgpu" fw-dir) #t)))
#t)))) (delete 'validate-runpath))))
(home-page "http://support.amd.com/en-us/download/linux") (home-page "http://support.amd.com/en-us/download/linux")
(synopsis "Nonfree firmware for AMD graphics chips") (synopsis "Nonfree firmware for AMD graphics chips")
(description "Nonfree firmware for AMD graphics chips. While most AMD (description "Nonfree firmware for AMD graphics chips. While most AMD