On 10/04/2022 14:23, Bruno Haible wrote:
On Guix 1.1 (x86_64): No test failures, but 1 test in is ERROR.


ERROR: tests/misc/stty
======================


+ stty_reversible_init_
++ tr '\n' ' '
++ perl -lne '/^ *{"(.*?)",.*\bREV\b/ and print $1' 
/home/guest/coreutils-9.0.193-54bec/build-64/../src/stty.c
../init.cfg: line 389: perl: command not found
+ stty_reversible_=' '
++ wc -w
++ echo ' '
+ test 62 -le 0
+ framework_failure_ 'too few reversible settings'

We should skip when missing perl in this case.
The attached should do that.

thanks,
Pádraig
From 046ab76166bfe946fa701e1a93ac69e1c69d5a13 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <p...@draigbrady.com>
Date: Sun, 10 Apr 2022 15:47:52 +0100
Subject: [PATCH] tests: stty.sh: skip on systems without perl

* init.cfg (stty_reversible_init_): Add require_perl_
to ensure we skip rather than error, without perl.
---
 init.cfg | 1 +
 1 file changed, 1 insertion(+)

diff --git a/init.cfg b/init.cfg
index 310ff055d..eb57de264 100644
--- a/init.cfg
+++ b/init.cfg
@@ -384,6 +384,7 @@ rwx_to_mode_()
 # with a space.
 stty_reversible_init_()
 {
+  require_perl_
   # Pad start with one space for the first option to match in query function.
   stty_reversible_=' '$(perl -lne '/^ *{"(.*?)",.*\bREV\b/ and print $1' \
     "$abs_top_srcdir"/src/stty.c | tr '\n' ' ')
-- 
2.26.2

Reply via email to