mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
Use 'mlambda' instead of 'memoize'.
* gnu/packages.scm (find-newest-available-packages): Use 'mlambda' instead of (memoize (lambda ...) ...). * gnu/packages/bootstrap.scm (package-with-bootstrap-guile): Likewise. * guix/build-system/gnu.scm (package-with-explicit-inputs)[rewritten-input]: Likewise. * guix/build-system/python.scm (package-with-explicit-python)[transform]: Likewise. * guix/derivations.scm (derivation->string): Likewise. * guix/gnu-maintenance.scm (gnu-package?): Likewise. * guix/modules.scm (module-file-dependencies): Likewise. * guix/scripts/graph.scm (standard-package-set): Likewise. * guix/scripts/lint.scm (official-gnu-packages*): Likewise. * guix/store.scm (store-regexp*): Likewise. * guix/utils.scm (location): Likewise.
This commit is contained in:
parent
f9704f179a
commit
55b2d92145
11 changed files with 204 additions and 216 deletions
|
@ -131,30 +131,29 @@ successful, or false to signal an error."
|
|||
(license gpl3+)))
|
||||
|
||||
(define package-with-bootstrap-guile
|
||||
(memoize
|
||||
(lambda (p)
|
||||
(mlambda (p)
|
||||
"Return a variant of P such that all its origins are fetched with
|
||||
%BOOTSTRAP-GUILE."
|
||||
(define rewritten-input
|
||||
(match-lambda
|
||||
((name (? origin? o))
|
||||
`(,name ,(bootstrap-origin o)))
|
||||
((name (? package? p) sub-drvs ...)
|
||||
`(,name ,(package-with-bootstrap-guile p) ,@sub-drvs))
|
||||
(x x)))
|
||||
((name (? origin? o))
|
||||
`(,name ,(bootstrap-origin o)))
|
||||
((name (? package? p) sub-drvs ...)
|
||||
`(,name ,(package-with-bootstrap-guile p) ,@sub-drvs))
|
||||
(x x)))
|
||||
|
||||
(package (inherit p)
|
||||
(source (match (package-source p)
|
||||
((? origin? o) (bootstrap-origin o))
|
||||
(s s)))
|
||||
(inputs (map rewritten-input
|
||||
(package-inputs p)))
|
||||
(native-inputs (map rewritten-input
|
||||
(package-native-inputs p)))
|
||||
(propagated-inputs (map rewritten-input
|
||||
(package-propagated-inputs p)))
|
||||
(replacement (and=> (package-replacement p)
|
||||
package-with-bootstrap-guile))))))
|
||||
(source (match (package-source p)
|
||||
((? origin? o) (bootstrap-origin o))
|
||||
(s s)))
|
||||
(inputs (map rewritten-input
|
||||
(package-inputs p)))
|
||||
(native-inputs (map rewritten-input
|
||||
(package-native-inputs p)))
|
||||
(propagated-inputs (map rewritten-input
|
||||
(package-propagated-inputs p)))
|
||||
(replacement (and=> (package-replacement p)
|
||||
package-with-bootstrap-guile)))))
|
||||
|
||||
(define* (glibc-dynamic-linker
|
||||
#:optional (system (or (and=> (%current-target-system)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue