summaryrefslogtreecommitdiff
path: root/contrib/packages
diff options
context:
space:
mode:
authorng0 <ng0@infotropique.org>2017-09-28 15:36:45 +0000
committerng0 <ng0@infotropique.org>2017-09-28 15:36:45 +0000
commita9946dabcb8ef0e13124930e70bb9060ad04eb5e (patch)
tree3a00b99a2ef36572dbb03bc565c237d5baa6dbf1 /contrib/packages
parent87ecda14a0c2a643c4f814b6603ae2cad207a218 (diff)
contrib: guix: Add gnunetg-test.
Build with testsuite but without experimental features.
Diffstat (limited to 'contrib/packages')
-rw-r--r--contrib/packages/guix/packages/gnunet/packages/gnunet.scm41
1 files changed, 41 insertions, 0 deletions
diff --git a/contrib/packages/guix/packages/gnunet/packages/gnunet.scm b/contrib/packages/guix/packages/gnunet/packages/gnunet.scm
index cb30572a1..fbc132d78 100644
--- a/contrib/packages/guix/packages/gnunet/packages/gnunet.scm
+++ b/contrib/packages/guix/packages/gnunet/packages/gnunet.scm
@@ -333,6 +333,47 @@
(zero? (system* "make" "check"))))))))
(synopsis "gnunet, full git with tests enabled with parallel tests")))
+(define-public gnunetg-test
+ (package
+ (inherit gnunetg)
+ (name "gnunetg-test")
+ (arguments
+ `(#:configure-flags
+ (list (string-append "--with-nssdir=" %output "/lib")
+ "--enable-gcc-hardening"
+ "--enable-linker-hardening"
+
+ ;;"--enable-poisoning"
+ ;;"--enable-sanitizer"
+ "--enable-logging=verbose"
+ "CFLAGS=-ggdb -O0")
+ ;; #:parallel-tests? #f ; parallel building seems to fail
+ ;;#:tests? #f ; fail: test_gnunet_statistics.py
+ #:phases
+ ;; swap check and install phases and set paths to installed bin
+ (modify-phases %standard-phases
+ (add-after 'unpack 'patch-bin-sh
+ (lambda _
+ (substitute* "bootstrap"
+ (("contrib/pogen.sh") "sh contrib/pogen.sh"))
+ (for-each (lambda (f) (chmod f #o755))
+ (find-files "po" ""))
+ #t))
+ (add-after 'patch-bin-sh 'bootstrap
+ (lambda _
+ (zero? (system* "sh" "bootstrap"))))
+ (delete 'check)
+ ;; XXX: https://gnunet.org/bugs/view.php?id=4619
+ (add-after 'install 'set-path-for-check
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (bin (string-append out "/bin"))
+ (lib (string-append out "/lib")))
+ (setenv "GNUNET_PREFIX" lib)
+ (setenv "PATH" (string-append (getenv "PATH") ":" bin))
+ (zero? (system* "make" "check"))))))))
+ (synopsis "gnunet, full git with tests enabled without experimental")))
+
;; ... and one package to test the package with "parallel-tests? #f"
(define-public gnunetgftn
(package