gnu: cpulimit: Use make-flags.
* gnu/packages/admin.scm (cpulimit)[arguments]: Introduce make-flags. Use them in custom 'build and 'check phases.master
parent
bc63198830
commit
6e26bd5b7f
|
@ -2383,17 +2383,18 @@ lookup to YAML Mode. You could enable the mode with @code{(add-hook
|
||||||
`(#:phases (modify-phases %standard-phases
|
`(#:phases (modify-phases %standard-phases
|
||||||
(delete 'configure)
|
(delete 'configure)
|
||||||
(replace 'build
|
(replace 'build
|
||||||
(lambda _
|
(lambda* (#:key make-flags #:allow-other-keys)
|
||||||
(invoke "make" (string-append "CC=" ,(cc-for-target)) "-Csrc")))
|
(apply invoke "make" "-Csrc" make-flags)))
|
||||||
(replace 'check
|
(replace 'check
|
||||||
(lambda _
|
(lambda* (#:key make-flags #:allow-other-keys)
|
||||||
(invoke "make" (string-append "CC=" ,(cc-for-target)) "-Ctests")))
|
(apply invoke "make" "-Ctests" make-flags)))
|
||||||
(replace 'install
|
(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"))
|
||||||
(bin (string-append out "/bin")))
|
(bin (string-append out "/bin")))
|
||||||
(install-file "src/cpulimit" bin))
|
(install-file "src/cpulimit" bin))
|
||||||
#t)))))
|
#t)))
|
||||||
|
#:make-flags (list (string-append "CC=" ,(cc-for-target)))))
|
||||||
(home-page "https://github.com/opsengine/cpulimit")
|
(home-page "https://github.com/opsengine/cpulimit")
|
||||||
(synopsis "Limit CPU usage")
|
(synopsis "Limit CPU usage")
|
||||||
(description
|
(description
|
||||||
|
|
Reference in New Issue