[Libguestfs] [PATCH libguestfs] maint: remove a subsumed syntax-check rule
Richard W.M. Jones
rjones at redhat.com
Mon Sep 17 10:06:04 UTC 2012
On Mon, Sep 17, 2012 at 11:51:05AM +0200, Jim Meyering wrote:
> Hi Rich,
>
> I noticed that libguestfs's cfg.mk had an old (and relatively
> inefficient) version of the rule that checks for empty lines at EOF.
> The one in maint.mk is much more efficient:
>
> >From cf93f04a980ec01ef37db9a0d4c7b99015169eee Mon Sep 17 00:00:00 2001
> From: Jim Meyering <meyering at redhat.com>
> Date: Mon, 17 Sep 2012 11:49:34 +0200
> Subject: [PATCH libguestfs] maint: remove a subsumed syntax-check rule
>
> * cfg.mk (sc_prohibit_trailing_blank_lines): Remove rule. It is now
> subsumed by the much more efficient sc_prohibit_empty_lines_at_EOF
> rule in gnulib's maint.mk.
> ---
> cfg.mk | 12 +-----------
> 1 file changed, 1 insertion(+), 11 deletions(-)
>
> diff --git a/cfg.mk b/cfg.mk
> index e619f0a..3b0b45e 100644
> --- a/cfg.mk
> +++ b/cfg.mk
> @@ -1,5 +1,5 @@
> # Customize Makefile.maint. -*- makefile -*-
> -# Copyright (C) 2003-2009 Free Software Foundation, Inc.
> +# Copyright (C) 2003-2012 Free Software Foundation, Inc.
>
> # This program is free software: you can redistribute it and/or modify
> # it under the terms of the GNU General Public License as published by
> @@ -115,16 +115,6 @@ sc_prohibit_gethostby:
> halt='use getaddrinfo, not gethostby*' \
> $(_sc_search_regexp)
>
> -# Disallow trailing blank lines.
> -sc_prohibit_trailing_blank_lines:
> - @$(VC_LIST_EXCEPT) \
> - | xargs perl -ln -0777 -e \
> - '-f $$ARGV or next; /\n\n+$$/ and print $$ARGV' > $@-t
> - @found=0; test -s $@-t && { found=1; cat $@-t 1>&2; \
> - echo '$(ME): found trailing blank line(s)' 1>&2; }; \
> - rm -f $@-t; \
> - test $$found = 0
> -
> # We don't use this feature of maint.mk.
> prev_version_file = /dev/null
>
> --
> 1.7.12.464.g83379df
Thanks, ACKed and pushed.
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
virt-df lists disk usage of guests without needing to install any
software inside the virtual machine. Supports Linux and Windows.
http://et.redhat.com/~rjones/virt-df/
More information about the Libguestfs
mailing list