me
/
guix
Archived
1
0
Fork 0

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.
master
Eric Bavier 2015-06-06 06:38:58 -05:00
parent dc7b1817f6
commit 84de458ba8
1 changed files with 4 additions and 1 deletions

View File

@ -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)))