From 7046e777212233b89df68379c270b448c45195ce Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Tue, 14 Jun 2022 08:55:03 +0200 Subject: system: compiler truly honors the 'system' argument. Fixes . * gnu/system.scm (operating-system-compiler): Parameterize '%current-system' and '%current-target-system' before calling 'operating-system-derivation'. * tests/system.scm ("lower-object, %current-system sensitivity"): New test. --- gnu/system.scm | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'gnu/system.scm') diff --git a/gnu/system.scm b/gnu/system.scm index 2c81478d00..ba1b7b5152 100644 --- a/gnu/system.scm +++ b/gnu/system.scm @@ -1582,8 +1582,13 @@ configurations." (lambda (store) ;; XXX: This is not super elegant but we can't pass SYSTEM and TARGET to ;; 'operating-system-derivation'. - (run-with-store store (operating-system-derivation os) - #:system system - #:target target))))) + (parameterize ((%current-system system) + (%current-target-system target)) + (run-with-store store + (mbegin %store-monad + (set-guile-for-build (default-guile)) + (operating-system-derivation os)) + #:system system + #:target target)))))) ;;; system.scm ends here -- cgit v1.2.3