sed lies to fool autoconf, but also confuses the toybox test suite.
Without this patch we're skipping all "toyonly" tests on both GNU and
toybox sed.
---
scripts/runtest.sh | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
From 8d983e22eae63d8adfe4484971730e062c7467ba Mon Sep 17 00:00:00 2001
From: Elliott Hughes <[email protected]>
Date: Thu, 3 Dec 2020 16:35:38 -0800
Subject: [PATCH] scripts/runtest.sh: fix `toyonly` for sed.
sed lies to fool autoconf, but also confuses the toybox test suite.
Without this patch we're skipping all "toyonly" tests on both GNU and
toybox sed.
---
scripts/runtest.sh | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/scripts/runtest.sh b/scripts/runtest.sh
index ddbf0549..33d479ab 100644
--- a/scripts/runtest.sh
+++ b/scripts/runtest.sh
@@ -81,7 +81,10 @@ skipnot()
toyonly()
{
IS_TOYBOX="$("$C" --version 2>/dev/null)"
- [ "${IS_TOYBOX/toybox/}" == "$IS_TOYBOX" ] && SKIPNEXT=1
+ # Ideally we'd just check for "toybox", but toybox sed lies to make autoconf
+ # happy, so we have at least two things to check for.
+ IS_TOYBOX_RE='(toybox|This is not GNU).*'
+ [[ "$IS_TOYBOX" =~ $IS_TOYBOX_RE ]] || SKIPNEXT=1
"$@"
}
--
2.29.2.576.ga3fc446d84-goog
_______________________________________________
Toybox mailing list
[email protected]
http://lists.landley.net/listinfo.cgi/toybox-landley.net