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