bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Fix sed script reading maint.mk.


From: Jim Meyering
Subject: Re: Fix sed script reading maint.mk.
Date: Tue, 09 Dec 2008 08:35:14 +0100

Ralf Wildenhues <address@hidden> wrote:
> Hello all,
>
> OK to apply?  Or would you rather have the $(srcdir)/ in $(ME)?

Hi Ralf,

That's fine by me, modulo the long line.  How about splitting it?

syntax-check-rules := \
  $(shell sed -n 's/^\(sc_[a-zA-Z0-9_-]*\):.*/\1/p' $(MYSELF))

I have a tiny preference to do keep $(srcdir) out of $(ME),
but won't object if anyone finds a good reason to put it there.

Thanks!

>     Fix sed script reading maint.mk.
>
>     * top/maint.mk (MYSELF): New macro, define as $(srcdir)/$(ME).
>     (syntax-check-rules): Use it.
>
> diff --git a/top/maint.mk b/top/maint.mk
> index 3756ee8..6d2ac03 100644
> --- a/top/maint.mk
> +++ b/top/maint.mk
> @@ -18,6 +18,7 @@
>  # along with this program.  If not, see <http://www.gnu.org/licenses/>.
>
>  ME := maint.mk
> +MYSELF := $(srcdir)/$(ME)
>
>  # List of all C-like source code files that will be tested for
>  # stylistic "errors".  You may want to define this to something
> @@ -100,7 +101,7 @@ sc_changelog:
>           exit 1; } || :
>
>  # Collect the names of rules starting with `sc_'.
> -syntax-check-rules := $(shell sed -n 's/^\(sc_[a-zA-Z0-9_-]*\):.*/\1/p' 
> $(ME))
> +syntax-check-rules := $(shell sed -n 's/^\(sc_[a-zA-Z0-9_-]*\):.*/\1/p' 
> $(MYSELF))
>  .PHONY: $(syntax-check-rules)
>
>  syntax-check: $(syntax-check-rules)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]