mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2025-01-26 20:49:29 -05:00
gexp: Disable deprecation warnings for 'imported-modules'.
Fixes <https://bugs.gnu.org/31450>. Reported by Martin Castillo <castilma@uni-bremen.de>. * guix/gexp.scm (gexp->derivation): Pass #:deprecation-warnings to 'imported-modules'. (imported-files): Add #:deprecation-warnings and pass #:env-vars to 'gexp->derivation'. (imported-modules): Add #:deprecation-warnings and pass it to 'imported-files'.
This commit is contained in:
parent
91e5885549
commit
30d722c392
1 changed files with 31 additions and 6 deletions
|
@ -664,7 +664,9 @@ (define (graphs-file-names graphs)
|
||||||
(imported-modules %modules
|
(imported-modules %modules
|
||||||
#:system system
|
#:system system
|
||||||
#:module-path module-path
|
#:module-path module-path
|
||||||
#:guile guile-for-build)
|
#:guile guile-for-build
|
||||||
|
#:deprecation-warnings
|
||||||
|
deprecation-warnings)
|
||||||
(return #f)))
|
(return #f)))
|
||||||
(compiled (if (pair? %modules)
|
(compiled (if (pair? %modules)
|
||||||
(compiled-modules %modules
|
(compiled-modules %modules
|
||||||
|
@ -974,7 +976,15 @@ (define %utils-module
|
||||||
(define* (imported-files files
|
(define* (imported-files files
|
||||||
#:key (name "file-import")
|
#:key (name "file-import")
|
||||||
(system (%current-system))
|
(system (%current-system))
|
||||||
(guile (%guile-for-build)))
|
(guile (%guile-for-build))
|
||||||
|
|
||||||
|
;; XXX: The only reason we have
|
||||||
|
;; #:deprecation-warnings is because (guix build
|
||||||
|
;; utils), which we use here, relies on _IO*, which
|
||||||
|
;; is deprecated in 2.2. On the next full-rebuild
|
||||||
|
;; cycle, we should disable such warnings
|
||||||
|
;; unconditionally.
|
||||||
|
(deprecation-warnings #f))
|
||||||
"Return a derivation that imports FILES into STORE. FILES must be a list
|
"Return a derivation that imports FILES into STORE. FILES must be a list
|
||||||
of (FINAL-PATH . FILE) pairs. Each FILE is mapped to FINAL-PATH in the
|
of (FINAL-PATH . FILE) pairs. Each FILE is mapped to FINAL-PATH in the
|
||||||
resulting store path. FILE can be either a file name, or a file-like object,
|
resulting store path. FILE can be either a file name, or a file-like object,
|
||||||
|
@ -1010,13 +1020,25 @@ (define build
|
||||||
(gexp->derivation name build
|
(gexp->derivation name build
|
||||||
#:system system
|
#:system system
|
||||||
#:guile-for-build guile
|
#:guile-for-build guile
|
||||||
#:local-build? #t)))
|
#:local-build? #t
|
||||||
|
|
||||||
|
;; TODO: On the next rebuild cycle, set to "no"
|
||||||
|
;; unconditionally.
|
||||||
|
#:env-vars
|
||||||
|
(case deprecation-warnings
|
||||||
|
((#f)
|
||||||
|
'(("GUILE_WARN_DEPRECATED" . "no")))
|
||||||
|
((detailed)
|
||||||
|
'(("GUILE_WARN_DEPRECATED" . "detailed")))
|
||||||
|
(else
|
||||||
|
'())))))
|
||||||
|
|
||||||
(define* (imported-modules modules
|
(define* (imported-modules modules
|
||||||
#:key (name "module-import")
|
#:key (name "module-import")
|
||||||
(system (%current-system))
|
(system (%current-system))
|
||||||
(guile (%guile-for-build))
|
(guile (%guile-for-build))
|
||||||
(module-path %load-path))
|
(module-path %load-path)
|
||||||
|
(deprecation-warnings #f))
|
||||||
"Return a derivation that contains the source files of MODULES, a list of
|
"Return a derivation that contains the source files of MODULES, a list of
|
||||||
module names such as `(ice-9 q)'. All of MODULES must be either names of
|
module names such as `(ice-9 q)'. All of MODULES must be either names of
|
||||||
modules to be found in the MODULE-PATH search path, or a module name followed
|
modules to be found in the MODULE-PATH search path, or a module name followed
|
||||||
|
@ -1041,7 +1063,8 @@ (define* (imported-modules modules
|
||||||
(cons f (search-path* module-path f))))))
|
(cons f (search-path* module-path f))))))
|
||||||
modules)))
|
modules)))
|
||||||
(imported-files files #:name name #:system system
|
(imported-files files #:name name #:system system
|
||||||
#:guile guile)))
|
#:guile guile
|
||||||
|
#:deprecation-warnings deprecation-warnings)))
|
||||||
|
|
||||||
(define* (compiled-modules modules
|
(define* (compiled-modules modules
|
||||||
#:key (name "module-import-compiled")
|
#:key (name "module-import-compiled")
|
||||||
|
@ -1056,7 +1079,9 @@ (define* (compiled-modules modules
|
||||||
#:system system
|
#:system system
|
||||||
#:guile guile
|
#:guile guile
|
||||||
#:module-path
|
#:module-path
|
||||||
module-path)))
|
module-path
|
||||||
|
#:deprecation-warnings
|
||||||
|
deprecation-warnings)))
|
||||||
(define build
|
(define build
|
||||||
(gexp
|
(gexp
|
||||||
(begin
|
(begin
|
||||||
|
|
Loading…
Reference in a new issue