diff --git a/guix/store.scm b/guix/store.scm index efba07bdcd..88cab1bb6a 100644 --- a/guix/store.scm +++ b/guix/store.scm @@ -1337,7 +1337,12 @@ (define (build-accumulator expected-store) (if (and (eq? (store-connection-socket store) (store-connection-socket expected-store)) (= mode (build-mode normal))) - (unresolved things continue) + (unresolved things + (lambda (new-store value) + ;; Borrow caches from NEW-STORE. + (set-store-connection-caches! + store (store-connection-caches new-store)) + (continue value))) (continue #t)))) (define default-cutoff @@ -1397,7 +1402,8 @@ (define-values (result rest) (if (unresolved? obj) ;; Pass #f because 'build-things' is now ;; unnecessary. - ((unresolved-continuation obj) #f) + ((unresolved-continuation obj) + store #f) obj)) result #:cutoff cutoff) (map/accumulate-builds store proc rest #:cutoff cutoff)))))