[aisleriot] games: Update guile-compile code from guile



commit 486616c22b8bda96deaa739ab2ae4888078c228d
Author: Christian Persch <chpe src gnome org>
Date:   Fri Dec 31 18:49:27 2021 +0100

    games: Update guile-compile code from guile

 games/guile-compile | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)
---
diff --git a/games/guile-compile b/games/guile-compile
index 1164f670..9b8b0109 100755
--- a/games/guile-compile
+++ b/games/guile-compile
@@ -10,6 +10,7 @@ shift 3
 export GUILE_AUTO_COMPILE=0
 export GUILE_LOAD_PATH=".:${srcdir}"
 export GUILE_LOAD_COMPILED_PATH=.
+export GUILE_WARN_DEPRECATED="detailed"
 
 exec ${GUILE:-/bin/false} -e '(@@ (guild) main)' -s "$this" "$@"
 !#
@@ -42,6 +43,8 @@ exec ${GUILE:-/bin/false} -e '(@@ (guild) main)' -s "$this" "$@"
 
 (primitive-load-path "api")
 
+;; Copied from guile code: guild
+
 (define-module (guild)
   #:use-module (ice-9 getopt-long)
   #:use-module (ice-9 command-line)
@@ -68,7 +71,13 @@ exec ${GUILE:-/bin/false} -e '(@@ (guild) main)' -s "$this" "$@"
 
 (define (main args)
   (if (defined? 'setlocale)
-      (setlocale LC_ALL ""))
+      (catch 'system-error
+        (lambda ()
+          (setlocale LC_ALL ""))
+        (lambda args
+          (format (current-error-port)
+                  "warning: failed to install locale: ~a~%"
+                  (strerror (system-error-errno args))))))
 
   (let* ((options (getopt-long args *option-grammar*
                                #:stop-at-first-non-option #t))


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]