On 02/03/2012 12:27 AM, Jim Meyering wrote: > Eric Blake wrote: >> * top/maint.mk (sc_makefile_at_at_check): Enhance check to cover >> lower case, like @top_srcdir@. >> >> Signed-off-by: Eric Blake <ebl...@redhat.com> >> --- >> >> Any objections to this? I noticed that libvirt had a mix >> of $(top_srcdir) and @top_srcdir@ in the same variable, and >> traced it to a weak syntax check not catching the difference. > > No objection. I vaguely recall deliberately omitting lower case > variables (maybe even for libvirt), to make the check less invasive. > > But please adjust it to use /.../i instead of adding a-z. > Better still, just use \w+ instead of the explicit [...]+.
Done with that change. >> sc_makefile_at_at_check: >> - @perl -ne '/\@[A-Z_0-9]+\@/' \ >> - -e ' && !/([A-Z_0-9]+)\s+=.*\@\1\@$$/' \ >> + @perl -ne '/\@[A-Za-z_0-9]+\@/' \ >> + -e ' && !/([A-Za-z_0-9]+)\s+=.*\@\1\@$$/' \ >> -e ''$(_makefile_at_at_check_exceptions) \ >> -e 'and (print "$$ARGV:$$.: $$_"), $$m=1; END {exit !$$m}' \ >> $$($(VC_LIST_EXCEPT) | grep -E '(^|/)(Makefile\.am|[^/]+\.mk)$$') \ > > -- Eric Blake ebl...@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature