diff options
author | Ludovic Courtès <ludo@gnu.org> | 2017-05-19 10:45:12 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2017-05-20 10:17:43 +0200 |
commit | 4ee6584cbfe5389db72f490f29e438f9935c2316 (patch) | |
tree | 23ebd04d6690c354ca1ff407af02c516e034d32e | |
parent | 4a628d57fc7956ae8a0fb167337d83ba66fe4f52 (diff) | |
download | gnu-guix-4ee6584cbfe5389db72f490f29e438f9935c2316.tar gnu-guix-4ee6584cbfe5389db72f490f29e438f9935c2316.tar.gz |
modules: Add more source-less modules.
* guix/modules.scm (%source-less-modules): New variable.
(source-module-dependencies): Use it.
-rw-r--r-- | guix/modules.scm | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/guix/modules.scm b/guix/modules.scm index 8c63f21a97..24b5903579 100644 --- a/guix/modules.scm +++ b/guix/modules.scm @@ -95,11 +95,16 @@ depends on." (('gnu _ ...) #t) (_ #f))) +(define %source-less-modules + ;; These are modules that have no corresponding source files or a source + ;; file different from what you'd expect. + '((system syntax) ;2.0, defined in boot-9 + (ice-9 ports internal) ;2.2, defined in (ice-9 ports) + (system syntax internal))) ;2.2, defined in boot-9 + (define* (source-module-dependencies module #:optional (load-path %load-path)) "Return the modules used by MODULE by looking at its source code." - ;; The (system syntax) module is a special-case because it has no - ;; corresponding source file (as of Guile 2.0.) - (if (equal? module '(system syntax)) + (if (member module %source-less-modules) '() (module-file-dependencies (search-path load-path |