summaryrefslogtreecommitdiff
path: root/guix/scripts
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2013-08-23 15:51:36 +0200
committerLudovic Courtès <ludo@gnu.org>2013-08-23 15:51:36 +0200
commit7db3ff4a29415ccc4f781c3e2450deb97d51a26f (patch)
tree459549425e83a80457a5261da57545c8e32f0455 /guix/scripts
parentbaed8816fcd6665319c342a1d4c117198af33dc2 (diff)
utils: Add `guile-version>?', and use it.
This fixes Guile version comparisons when (version) has a vendor-specific suffix. Reported by Andreas Enge <andreas@enge.fr>. * guix/utils.scm (guile-version>?): New procedure. * tests/utils.scm ("guile-version>? 1.8", "guile-version>? 10.5"): New tests. * guix/scripts/substitute-binary.scm (fetch, progress-report-port): Use `guile-version>?' instead of `version>?'. * guix/http-client.scm (when-guile<=2.0.5, http-fetch): Likewise.
Diffstat (limited to 'guix/scripts')
-rwxr-xr-xguix/scripts/substitute-binary.scm4
1 files changed, 2 insertions, 2 deletions
diff --git a/guix/scripts/substitute-binary.scm b/guix/scripts/substitute-binary.scm
index 4a013fe277..97bbfcbce8 100755
--- a/guix/scripts/substitute-binary.scm
+++ b/guix/scripts/substitute-binary.scm
@@ -155,7 +155,7 @@ provide."
;; and then cancel with:
;; sudo tc qdisc del dev eth0 root
(let ((port #f))
- (with-timeout (if (or timeout? (version>? (version) "2.0.5"))
+ (with-timeout (if (or timeout? (guile-version>? "2.0.5"))
%fetch-timeout
0)
(begin
@@ -417,7 +417,7 @@ PORT. REPORT-PROGRESS is a two-argument procedure such as that returned by
;; Since `http-fetch' in Guile 2.0.5 returns all the data once it's done,
;; don't pretend to report any progress in that case.
- (if (version>? (version) "2.0.5")
+ (if (guile-version>? "2.0.5")
(make-custom-binary-input-port "progress-port-proc"
read! #f #f
(cut close-port port))