summaryrefslogtreecommitdiff
path: root/guix
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2019-07-03 22:27:17 +0200
committerLudovic Courtès <ludo@gnu.org>2019-07-03 23:44:19 +0200
commit1653b23564b7de02440820d07ed067318ebf13b4 (patch)
tree9c1f76fafb207c648ee39e64bc9b33c8732de245 /guix
parente6a57949f6ca80853b44a3225f0e727cb457e661 (diff)
derivations: 'map-derivation' no longer calls 'read-derivation-from-file'.
This is a followup to 5cf4b26d52bcea382d98fb4becce89be9ee37b55. * guix/derivations.scm (map-derivation)[rewritten-input]: Avoid call to 'read-derivation-from-file'.
Diffstat (limited to 'guix')
-rw-r--r--guix/derivations.scm8
1 files changed, 3 insertions, 5 deletions
diff --git a/guix/derivations.scm b/guix/derivations.scm
index 9cacca572e..4e969cb1a0 100644
--- a/guix/derivations.scm
+++ b/guix/derivations.scm
@@ -948,16 +948,14 @@ recursively."
;; in the format used in 'derivation' calls.
(mlambda (input loop)
(match input
- (($ <derivation-input> (= derivation-file-name path)
- (sub-drvs ...))
- (match (vhash-assoc path mapping)
+ (($ <derivation-input> drv (sub-drvs ...))
+ (match (vhash-assoc (derivation-file-name drv) mapping)
((_ . (? derivation? replacement))
(cons replacement sub-drvs))
((_ . replacement)
(list replacement))
(#f
- (let* ((drv (loop (read-derivation-from-file path))))
- (cons drv sub-drvs))))))))
+ (cons (loop drv) sub-drvs)))))))
(let loop ((drv drv))
(let* ((inputs (map (cut rewritten-input <> loop)