diff options
author | Tobias Geerinckx-Rice <me@tobias.gr> | 2023-07-16 02:00:01 +0200 |
---|---|---|
committer | Tobias Geerinckx-Rice <me@tobias.gr> | 2023-07-16 02:00:02 +0200 |
commit | 4c20d7a661f457f52b7bc80f1c99c4f25e5af0d2 (patch) | |
tree | 3e79be1609069646696da48dbbe0976a06432b76 /gnu/packages | |
parent | 84779e6271bdcde6033ad4339502e421b2efd1a4 (diff) |
gnu: hwinfo: Make with flags.
* gnu/packages/hardware.scm (hwinfo)[arguments]: Move CC, LIBDIR, and
VERSION from hacky substitutions to superior #:make-flags. Honour them
in the 'build phase.
Diffstat (limited to 'gnu/packages')
-rw-r--r-- | gnu/packages/hardware.scm | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/gnu/packages/hardware.scm b/gnu/packages/hardware.scm index 68f06917c6..2566339a2a 100644 --- a/gnu/packages/hardware.scm +++ b/gnu/packages/hardware.scm @@ -362,6 +362,10 @@ operability and find drivers.") (arguments (list #:tests? #f ; no test-suite available + #:make-flags + #~(list (string-append "CC=" #$(cc-for-target)) + (string-append "LIBDIR=" #$output:lib "/lib") + (string-append "VERSION=" #$version)) #:phases #~(modify-phases %standard-phases (add-after 'unpack 'patch @@ -378,10 +382,6 @@ operability and find drivers.") (string-append "OUTPUT_DIRECTORY = " doc "/libhd"))) ;; Correct values of the version and install directories. (substitute* "Makefile" - (("VERSION.*\\:=.*$") - (string-append "VERSION := " #$version "\n")) - (("LIBDIR.*\\?=.*$") - (string-append "LIBDIR ?= " lib "\n")) (("/usr/include") include) (("/(usr|var)/(lib|lib64)") lib) (("/usr/sbin") sbin) @@ -400,9 +400,8 @@ operability and find drivers.") (delete 'configure) (replace 'build (lambda* (#:key make-flags #:allow-other-keys) - (setenv "CC" #$(cc-for-target)) - (invoke "make" "shared") - (invoke "make" "doc"))) + (apply invoke "make" "shared" make-flags) + (apply invoke "make" "doc" make-flags))) (add-after 'install 'install-man-pages (lambda _ (for-each |