From 870677cbb85d05688ba85deb9807fdef8bd94e19 Mon Sep 17 00:00:00 2001 From: Ludovic Courtès Date: Mon, 18 Jun 2018 15:16:40 +0200 Subject: compile: Work around non-thread-safe module autoloading. * guix/build/compile.scm : Set 'try-module-autoload' when running on Guile < 2.2.4. --- guix/build/compile.scm | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'guix/build') diff --git a/guix/build/compile.scm b/guix/build/compile.scm index 7b6e31107c..5a1363556a 100644 --- a/guix/build/compile.scm +++ b/guix/build/compile.scm @@ -196,6 +196,20 @@ files are for HOST, a GNU triplet such as \"x86_64-linux-gnu\"." (unless (zero? total) (report-compilation #f total total))))) +(eval-when (eval load) + (when (and (string=? "2" (major-version)) + (or (string=? "0" (minor-version)) + (and (string=? (minor-version) "2") + (< (string->number (micro-version)) 4)))) + ;; Work around on Guile < 2.2.4. + ;; Serialize 'try-module-autoload' calls. + (set! (@ (guile) try-module-autoload) + (let ((mutex (make-mutex 'recursive)) + (real (@ (guile) try-module-autoload))) + (lambda* (module #:optional version) + (with-mutex mutex + (real module version))))))) + ;;; Local Variables: ;;; eval: (put 'with-augmented-search-path 'scheme-indent-function 2) ;;; eval: (put 'with-target 'scheme-indent-function 1) -- cgit v1.2.3 From b194da0d6833ee2767b5df34105d12e456c52368 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 19 Jun 2018 10:40:39 +0200 Subject: build-system/waf: Use invoke. * guix/build/waf-build-system.scm (call-waf): Use "invoke" and unconditionally return #t. --- guix/build/waf-build-system.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'guix/build') diff --git a/guix/build/waf-build-system.scm b/guix/build/waf-build-system.scm index f0364e867d..56048e7685 100644 --- a/guix/build/waf-build-system.scm +++ b/guix/build/waf-build-system.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015 Ricardo Wurmus +;;; Copyright © 2015, 2018 Ricardo Wurmus ;;; ;;; This file is part of GNU Guix. ;;; @@ -38,7 +38,8 @@ (begin (format #t "running \"python waf\" with command ~s and parameters ~s~%" command params) - (zero? (apply system* "python" "waf" command params))) + (apply invoke "python" "waf" command params) + #t) (error "no waf found"))) (define* (configure #:key target native-inputs inputs outputs -- cgit v1.2.3