summaryrefslogtreecommitdiff
path: root/Makefile.maint
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2002-11-14 12:09:16 +0000
committerJim Meyering <jim@meyering.net>2002-11-14 12:09:16 +0000
commitf6af3459220570436100ebbb4b1dd65db450c6c1 (patch)
treeaf6de36eabe2e0312581f598f6fe2123fdecc3e8 /Makefile.maint
parentc3d9348a86b93cb1b7b50825d0a414c0d2924025 (diff)
downloadcoreutils-f6af3459220570436100ebbb4b1dd65db450c6c1.tar.xz
Sync with Bison, i.e.:
(po-check): Scan .l and .y files instead of the .c and the .h files that they generate. This fixes the bug reported by Tim Van Holder in: <http://mail.gnu.org/pipermail/bison-patches/2002-November/001352.html> Look for N_ as well as for _. Try to avoid matching #define for N_ and _. From Paul Eggert.
Diffstat (limited to 'Makefile.maint')
-rw-r--r--Makefile.maint11
1 files changed, 10 insertions, 1 deletions
diff --git a/Makefile.maint b/Makefile.maint
index 4b25ad36a..dcf665a20 100644
--- a/Makefile.maint
+++ b/Makefile.maint
@@ -97,7 +97,16 @@ m4-check:
po-check:
if test -f po/POTFILES.in; then \
grep -E -v '^(#|$$)' po/POTFILES.in | sort > $@-1; \
- grep -E -l '\b_\(' lib/*.[ch] src/*.[ch] | sort > $@-2; \
+ files=; \
+ for file in lib/*.[chly] src/*.[chly]; do \
+ case $$file in \
+ *.[ch]) \
+ base=`expr " $$file" : ' \(.*\)\..'`; \
+ { test -f $$base.l || test -f $$base.y; } && continue;; \
+ esac; \
+ files="$$files $$file"; \
+ done; \
+ grep -E -l '\bN?_\([^)"]*("|$$)' $$files | sort > $@-2; \
diff -u $@-1 $@-2 || exit 1; \
rm -f $@-1 $@-2; \
fi