gnu: hdf5: Allow for absence of utility script.
authorPaul Garlick <pgarlick@tourbillion-technology.com>
Thu, 20 Sep 2018 17:59:56 +0000 (18:59 +0100)
committerLudovic Courtès <ludo@gnu.org>
Fri, 21 Sep 2018 15:04:37 +0000 (17:04 +0200)
* gnu/packages/maths.scm (hdf5)[arguments]: Add condition to 'split'
phase to check for existence of h5fc script.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
gnu/packages/maths.scm

index 736bac1..30f1610 100644 (file)
@@ -814,8 +814,11 @@ incompatible with HDF5.")
                 (mkdir-p flib)
                 (mkdir-p finc)
                 (mkdir-p fex)
-                (rename-file (string-append bin "/h5fc")
-                             (string-append fbin "/h5fc"))
+                ;; Note: When built with --enable-parallel, the 'h5fc' file
+                ;; doesn't exist, hence this condition.
+                (when (file-exists? (string-append bin "/h5fc"))
+                  (rename-file (string-append bin "/h5fc")
+                               (string-append fbin "/h5fc")))
                 (for-each (lambda (file)
                             (rename-file file
                                          (string-append flib "/" (basename file))))