From f7e6a84e989295d86e8c776988f65c36df117095 Mon Sep 17 00:00:00 2001 From: Lars Bilke Date: Fri, 8 Mar 2024 12:08:11 +0100 Subject: [PATCH] gnu: hypre: Honor the #:tests? flag. * gnu/packages/maths.scm (hypre)[arguments]: Adjust 'check phase to honor the #:tests? flag. Change-Id: I475fabd7d9f73ed320b97a4767830d82190c2b15 Signed-off-by: Efraim Flashner --- gnu/packages/maths.scm | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index bb2d7a3504..52ab4d66a0 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -7136,16 +7136,21 @@ (define-public hypre (lambda _ (invoke "make" "-C" "docs"))) (replace 'check - (lambda _ - (setenv "LD_LIBRARY_PATH" (string-append (getcwd) "/hypre/lib")) - (setenv "PATH" (string-append "." ":" (getenv "PATH"))) - (invoke "make" "check" "CHECKRUN=") - (for-each (lambda (filename) - (let ((size (stat:size (stat filename)))) - (when (positive? size) - (error (format #f "~a size ~d; error indication~%" - filename size))))) - (find-files "test" ".*\\.err$")))) + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (setenv "LD_LIBRARY_PATH" + (string-append (getcwd) "/hypre/lib")) + (setenv "PATH" + (string-append "." ":" + (getenv "PATH"))) + (invoke "make" "check" "CHECKRUN=") + (for-each (lambda (filename) + (let ((size (stat:size (stat filename)))) + (when (positive? size) + (error (format #f + "~a size ~d; error indication~%" + filename size))))) + (find-files "test" ".*\\.err$"))))) (add-after 'install 'install-docs (lambda* (#:key outputs #:allow-other-keys) ;; Custom install because docs/Makefile doesn't honor ${docdir}.