Browse Source

profiles: Search for ghc conf files only if package db exists.

This avoids having 'find-files' report warnings about searching in
non-existent directories.

* guix/profiles.scm (ghc-package-cache-file)[conf-files]: Only search
  for *.conf files if the search directory exists.
gn-latest-20200428
Eric Bavier 6 years ago
parent
commit
84de458ba8
  1. 5
      guix/profiles.scm

5
guix/profiles.scm

@ -500,7 +500,10 @@ entries of MANIFEST, or #f if MANIFEST does not have any GHC packages."
(string-append #$output "/" db-subdir))
(define (conf-files top)
(find-files (string-append top "/" db-subdir) "\\.conf$"))
(let ((db (string-append top "/" db-subdir)))
(if (file-exists? db)
(find-files db "\\.conf$")
'())))
(define (copy-conf-file conf)
(let ((base (basename conf)))

Loading…
Cancel
Save