Mercurial > hg > octave-nkf > gnulib-hg
changeset 13378:c4a059473950
maint.mk: also prohibit "#undef" of always-defined symbols
* top/maint.mk (def_sym_regex): Handle #undef as well as #define.
Allow more than one space before the symbol name.
(sc_prohibit_always-defined_macros): Use grep's -E, now that
the regexp uses alternation.
author | Jim Meyering <meyering@redhat.com> |
---|---|
date | Thu, 27 May 2010 13:33:04 +0200 |
parents | d810a6f1c43c |
children | d62002e5d9f4 |
files | ChangeLog top/maint.mk |
diffstat | 2 files changed, 11 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2010-05-27 Jim Meyering <meyering@redhat.com> + + maint.mk: also prohibit "#undef" of always-defined symbols + * top/maint.mk (def_sym_regex): Handle #undef as well as #define. + Allow more than one space before the symbol name. + (sc_prohibit_always-defined_macros): Use grep's -E, now that + the regexp uses alternation. + 2010-05-26 Eric Blake <eblake@redhat.com> maint.mk: avoid echo -e
--- a/top/maint.mk +++ b/top/maint.mk @@ -689,7 +689,8 @@ perl -lne '$(gl_extract_significant_defines_)' $$f; \ done; \ ) | sort -u \ - | sed 's/^/^ *# *define /;s/$$/\\>/' + | grep -Ev '^ATTRIBUTE_NORETURN' \ + | sed 's/^/^ *# *(define|undef) */;s/$$/\\>/' endef # Don't define macros that we already get from gnulib header files. @@ -698,7 +699,7 @@ case $$(echo all: | grep -l -f - Makefile) in Makefile);; *) \ echo '$(ME): skipping $@: you lack GNU grep' 1>&2; exit 0;; \ esac; \ - $(def_sym_regex) | grep -f - $$($(VC_LIST_EXCEPT)) \ + $(def_sym_regex) | grep -E -f - $$($(VC_LIST_EXCEPT)) \ && { echo '$(ME): define the above via some gnulib .h file' \ 1>&2; exit 1; } || :; \ fi