autoconf-patches
[Top][All Lists]
Advanced

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

Re: [PATCH] Don't infloop upon "make dist".


From: Ralf Wildenhues
Subject: Re: [PATCH] Don't infloop upon "make dist".
Date: Sun, 2 Mar 2008 21:33:37 +0100
User-agent: Mutt/1.5.17+20080114 (2008-01-14)

* Jim Meyering wrote on Sun, Mar 02, 2008 at 05:39:07PM CET:
> I noticed that "make dist" would infloop.
> This change fixes that and syncs the pieces
> from coreutils and gnulib:
> 
>       Don't infloop upon "make dist".
>       * GNUmakefile: Merge from coreutils.
>       * Makefile.am (dist-hook): Inject .tarball-version into tarball,
>       not .version.
>       * configure.ac (AC_INIT): Use .tarball-version, not .version.
>       * build-aux/git-version-gen: Update from gnulib.
> 
> Ok to commit?

Can you explain the infloop to me, because I have not experienced such
a loop.  Is that because I do not build in-tree?  Note that I do have
symlinks $builddir/GNUmakefile -> $srcdir/GNUmakefile and similar for
Makefile.maint.  Without your patch, I get

| Usage: ../autoconf/build-aux/git-version-gen $srcdir/.version
| INFO: running autoreconf for new version string; old:

and up to two reruns of autoreconf (only one if the files are already up
to date).  With your patch I get

| INFO: running autoreconf for new version string: UNKNOWN
| autoreconf: Entering directory `.'

which is only one rerun, but it also happens with all files already up
to date.

Thanks,
Ralf

> --- a/GNUmakefile
> +++ b/GNUmakefile
> @@ -4,18 +4,18 @@
>  # It is necessary if you want to build targets usually of interest
>  # only to the maintainer.
> 
> -# Copyright (C) 2001, 2003, 2006-2007 Free Software Foundation, Inc.
> +# Copyright (C) 2001, 2003, 2006-2008 Free Software Foundation, Inc.

Please don't add ranges, but individual years, comma-separated.

>  # 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
>  # the Free Software Foundation, either version 3 of the License, or
>  # (at your option) any later version.
> -#
> +

What's this good for except possibly interfering with a later scripted
change of many files' copyright statements (two instances)?

>  # This program is distributed in the hope that it will be useful,
>  # but WITHOUT ANY WARRANTY; without even the implied warranty of
>  # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>  # GNU General Public License for more details.
> -#
> +
>  # You should have received a copy of the GNU General Public License
>  # along with this program.  If not, see <http://www.gnu.org/licenses/>.


> @@ -49,10 +49,11 @@ include Makefile
>  ifeq (0,$(MAKELEVEL))
>    _is-dist-target = $(filter dist% alpha beta major,$(MAKECMDGOALS))
>    ifneq (,$(_is-dist-target))
> -    _curr-ver := $(shell $(srcdir)/build-aux/git-version-gen $(srcdir) 
> .version)
> +    _curr-ver := $(shell $(srcdir)/build-aux/git-version-gen \
> +                   $(srcdir)/.tarball-version)
>      ifneq ($(_curr-ver),$(VERSION))
> -      $(info INFO: running autoreconf for new version string; old: 
> $(_curr-ver))
> -      dummy := $(shell                               \
> +      $(info INFO: running autoreconf for new version string: $(_curr-ver))
> +      _dummy := $(shell                              \
>       rm -rf autom4te.cache;                  \
>       (cd $(srcdir) && autoreconf -i -v)      \
>         && rm -f INSTALL)

Actually, this autoreconf invocation should have $build_tree/tests as
first $PATH entry, so that in-tree auto* are used if present.  I'm not
sure if I really want this, because in order to be consistent, all other
rebuilding rules in all Makefiles should then be overridden as well, but
it'd be The Right Thing.  Hmm.

Cheers,
Ralf




reply via email to

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