gnu: multipath-tools: Enable tests.
* gnu/packages/linux.scm (multipath-tools)[arguments]: Remove #:tests?. Add #:test-target. Add phase to add missing linker flag. [native-inputs]: Add CMOCKA.master
parent
cb6d4aff44
commit
bc0e5133ae
|
@ -4205,7 +4205,7 @@ arrays when needed.")
|
||||||
#t))))
|
#t))))
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
'(#:tests? #f ; no tests
|
'(#:test-target "test"
|
||||||
#:parallel-build? #f ;XXX: broken in 0.8.4
|
#:parallel-build? #f ;XXX: broken in 0.8.4
|
||||||
#:make-flags (list "CC=gcc"
|
#:make-flags (list "CC=gcc"
|
||||||
(string-append "DESTDIR="
|
(string-append "DESTDIR="
|
||||||
|
@ -4242,11 +4242,22 @@ arrays when needed.")
|
||||||
(("bool is_queueing;")
|
(("bool is_queueing;")
|
||||||
"bool is_queueing = false;"))
|
"bool is_queueing = false;"))
|
||||||
#t))
|
#t))
|
||||||
|
(add-after 'unpack 'fix-linking-tests
|
||||||
|
(lambda _
|
||||||
|
;; Add missing linker flag for -lmpathcmd. This should be fixed
|
||||||
|
;; for versions > 0.8.4.
|
||||||
|
(substitute* "tests/Makefile"
|
||||||
|
(("-lmultipath -lcmocka")
|
||||||
|
"-lmultipath -L$(mpathcmddir) -lmpathcmd -lcmocka"))
|
||||||
|
#t))
|
||||||
(delete 'configure)))) ; no configure script
|
(delete 'configure)))) ; no configure script
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("perl" ,perl)
|
`(("perl" ,perl)
|
||||||
("pkg-config" ,pkg-config)
|
("pkg-config" ,pkg-config)
|
||||||
("valgrind" ,valgrind)))
|
("valgrind" ,valgrind)
|
||||||
|
|
||||||
|
;; For tests.
|
||||||
|
("cmocka" ,cmocka)))
|
||||||
(inputs
|
(inputs
|
||||||
`(("json-c" ,json-c)
|
`(("json-c" ,json-c)
|
||||||
("libaio" ,libaio)
|
("libaio" ,libaio)
|
||||||
|
|
Reference in New Issue