Re: [bug #65812] make dist includes bnary file

Bernhard Voelker <[email protected]>
Newsgroups gmane.comp.gnu.findutils.bugs
Message-ID <[email protected]>
On 5/30/24 21:27, James Youngman wrote:
> Fixed in git, with attached patch.
>    <https://savannah.gnu.org/bugs/?65812>

Thanks.
This introduced a syntax-check failure.
Fixed with the attached 2 commits.

* [PATCH 1/2] maint: improve ERE in sc_tests_list_consistency
* [PATCH 2/2] tests: re-introduce all_tests needed by syntax-check

Have a nice day,
Berny
0001-maint-improve-ERE-in-sc_tests_list_consistency.patch (text/x-patch, 1.1 KB)
From 3d822be55af9eec550c50e4bca70113dd02e1f82 Mon Sep 17 00:00:00 2001
From: Bernhard Voelker <[email protected]>
Date: Sat, 1 Jun 2024 16:10:53 +0200
Subject: [PATCH 1/2] maint: improve ERE in sc_tests_list_consistency

The ERE used lacks the grouping of the extensions and therefore would
also match files where the first two patterns are not at the end of
the line:
  grep -E '\.sh|\.c$'

* cfg.mk (sc_tests_list_consistency): Add grouping (...) around the
sub-patterns.  While at it, also remove the redundant escaping, i.e.,
\$$ -> $$ to be consistent with the rest of this file.
---
 cfg.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/cfg.mk b/cfg.mk
index 60bc8cd5..ffa3f264 100644
--- a/cfg.mk
+++ b/cfg.mk
@@ -116,7 +116,7 @@ sc_tests_list_consistency:
 	  cd $(top_srcdir);						\
 	  $(SHELL) build-aux/vc-list-files tests			\
 	    | grep -Ev '^tests/init\.sh$$'				\
-	    | grep -E "$$test_extensions_rx\$$"				\
+	    | grep -E "($$test_extensions_rx)$$"			\
 	    | sed 's/\.c$$//';						\
 	} | sort | uniq -u | grep . && exit 1; :
 
-- 
2.45.1
0002-tests-re-introduce-all_tests-needed-by-syntax-check.patch (text/x-patch, 1.1 KB)
From 7daec5921ea3318d0a1a5f187b7e74b447a0c136 Mon Sep 17 00:00:00 2001
From: Bernhard Voelker <[email protected]>
Date: Sat, 1 Jun 2024 16:28:17 +0200
Subject: [PATCH 2/2] tests: re-introduce all_tests needed by syntax-check

The recent commit removed the variable 'all_tests' which is used by
sc_tests_list_consistency in cfg.mk.

* tests/local.mk (all_tests): Re-introduce and ...
(TESTS): ... use it here.
---
 tests/local.mk | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tests/local.mk b/tests/local.mk
index b7cbdbbd..1fe14c01 100644
--- a/tests/local.mk
+++ b/tests/local.mk
@@ -20,7 +20,9 @@ built_programs = find xargs frcode locate updatedb
 # Indirections required so that we'll still be able to know the
 # complete list of our tests even if the user overrides TESTS
 # from the command line (as permitted by the test harness API).
-TESTS = $(sh_tests) $(binary_tests)
+# The check 'sc_tests_list_consistency' also uses 'all_tests'.
+all_tests = $(sh_tests) $(binary_tests)
+TESTS = $(all_tests)
 root_tests = $(all_root_tests)
 
 EXTRA_DIST += $(sh_tests)
-- 
2.45.1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.