gnu: gn: Enable tests.

* gnu/packages/build-tools.scm (gn)[arguments]: Remove #:tests?.  Override
'check' phase.
This commit is contained in:
Marius Bakke 2019-11-14 16:59:37 +01:00
parent d922724521
commit 97b672d99f
No known key found for this signature in database
GPG key ID: A2A06DF2A33A54FA

View file

@ -117,8 +117,7 @@ (define-public gn
(file-name (git-file-name name version))))
(build-system gnu-build-system)
(arguments
`(#:tests? #f ;FIXME: How to run?
#:phases (modify-phases %standard-phases
`(#:phases (modify-phases %standard-phases
(add-before 'configure 'set-build-environment
(lambda _
(setenv "CC" "gcc") (setenv "CXX" "g++")
@ -142,6 +141,14 @@ (define-public gn
(lambda _
(invoke "ninja" "-C" "out" "gn"
"-j" (number->string (parallel-job-count)))))
(replace 'check
(lambda* (#:key (tests? #t) #:allow-other-keys)
(if tests?
(lambda ()
(invoke "ninja" "-C" "out" "gn_unittests"
"-j" (number->string (parallel-job-count)))
(invoke "./out/gn_unittests"))
(format #t "test suite not run~%"))))
(replace 'install
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))