self: Use Guile 2.2 unconditionally for recent 'guix pull'.
authorLudovic Courtès <ludo@gnu.org>
Wed, 10 Oct 2018 12:54:18 +0000 (14:54 +0200)
committerLudovic Courtès <ludo@gnu.org>
Wed, 10 Oct 2018 12:54:18 +0000 (14:54 +0200)
Fixes <https://bugs.gnu.org/32929>.
Reported by Michael Bowcutt <mwb71@case.edu>.

* guix/self.scm (guix-derivation)[guile]: Use "2.2" when PULL-VERSION >= 1.
Likewise for the #:guile-version argument.

guix/self.scm

index 126116e..ecf8464 100644 (file)
@@ -911,7 +911,11 @@ is not supported."
         version))
 
   (define guile
-    (guile-for-build guile-version))
+    ;; When PULL-VERSION >= 1, produce a self-contained Guix and use Guile 2.2
+    ;; unconditionally.
+    (guile-for-build (if (>= pull-version 1)
+                         "2.2"
+                         guile-version)))
 
   (mbegin %store-monad
     (set-guile-for-build guile)
@@ -920,9 +924,11 @@ is not supported."
                                #:name (string-append "guix-"
                                                      (shorten version))
                                #:pull-version pull-version
-                               #:guile-version (match guile-version
-                                                 ("2.2.2" "2.2")
-                                                 (version version))
+                               #:guile-version (if (>= pull-version 1)
+                                                   "2.2"
+                                                   (match guile-version
+                                                     ("2.2.2" "2.2")
+                                                     (version version)))
                                #:guile-for-build guile)))
       (if guix
           (lower-object guix)