From 3a14f695328f325676fbef914a57c34172fd7cf5 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Mon, 28 Mar 2005 19:22:36 +0000 Subject: [PATCH] (sc_tight_scope): Adjust to catch any new declarations like that of stty.c's `speeds'. --- src/Makefile.am | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Makefile.am b/src/Makefile.am index 5e8575f433..24ca5e571a 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -326,9 +326,11 @@ sc_tight_scope: $(all_programs) | grep -Ev -f $$t && \ { echo 'the above functions should have static scope' 1>&2; \ exit 1; } || : ; \ - printf '^program_name$$\n' > $$t; \ + ( printf '^program_name$$\n'; \ + sed -n 's/^extern int \([^ ][^ ]*\);$$/^\1$$/p' \ + $(noinst_HEADERS) ) > $$t; \ nm -e *.$(OBJEXT) \ - | sed -n 's/.* B //p' \ + | sed -n 's/.* [BD] //p' \ | grep -Ev -f $$t && \ { echo 'the above variables should have static scope' 1>&2; \ exit 1; } || : -- 2.47.3