bug-gnulib
[Top][All Lists]
Advanced

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

Re: maintainer-makefile vs vc-list-files/useless-if-before-free


From: Eric Blake
Subject: Re: maintainer-makefile vs vc-list-files/useless-if-before-free
Date: Mon, 27 Apr 2009 06:29:07 -0600
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.21) Gecko/20090302 Thunderbird/2.0.0.21 Mnenhy/0.7.6.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Simon Josefsson on 4/27/2009 6:19 AM:
>> The intent is that your cfg.mk should point to the location where you
>> expect to find a fresh gnulib checkout, so that you DON'T have to add
>> a dependency on vc-list-files or useless-if-before-free.  Using
>> maint.mk from gnulib implies that you have gnulib installed, which is
>> why I was okay writing it in this way.
> 
> I don't think that is true -- I have been using maint.mk in several
> projects without requiring a locally installed gnulib repository for
> bootstrapping.
> Given the above, this seems wrong to me.  Instead, why don't maint.mk
> use the local build-aux/ path?  Right now it looks in the gnulib
> directory (gnulib/) but the right thing seems like the maintainer should
> --import vc-list-files and useless-if-before-free (possibly
> maintainer-makefile should depend on them) and then maint.mk should call
> the files from the locally imported build-aux/ directory.  Right?

Yes, if we go this route, then we should make the maintainer-makefile
module depend on both vc-list-files and useless-if-before-free.  I almost
made this change as part of porting maint.mk to work with m4, but didn't
do it because m4 falls in the first camp (bootstrap requires a gnulib
checkout), but your arguments for the second camp (bootstrap is
independent of gnulib) are good, so how about this patch instead?

vc-list-files is a definite dependency, although I could be convinced to
drop the dependency on useless-if-before-free for projects that choose to
skip that particular syntax check, provided we also rewrite that check to
first validate that build-aux/useless-if-before-free has been imported.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkn1pRIACgkQ84KuGfSFAYCR7QCfel0o1fV6YXaMwdOrFxYiaepO
IT0AoJg1pQR6jeze3zMK0oaBlo6dqM/q
=KfDx
-----END PGP SIGNATURE-----
>From 3262ad571e1c6dbfde5e7350e2d5745d59b72fcb Mon Sep 17 00:00:00 2001
From: Eric Blake <address@hidden>
Date: Mon, 27 Apr 2009 06:27:04 -0600
Subject: [PATCH] maintainer-makefile: depend on all required helper scripts

* modules/maintainer-makefile (Depends-on): Add vc-list-files and
useless-if-before-free.
* top/maint.mk (VC_LIST, sc_avoid_if_before_free): Use local
version, rather than assuming gnulib checkout is available.
Reported by Simen Josefsson.

Signed-off-by: Eric Blake <address@hidden>
---
 ChangeLog                   |    9 +++++++++
 modules/maintainer-makefile |    2 ++
 top/maint.mk                |    4 ++--
 3 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 66e7c28..43dfc44 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2009-04-27  Eric Blake  <address@hidden>
+
+       maintainer-makefile: depend on all required helper scripts
+       * modules/maintainer-makefile (Depends-on): Add vc-list-files and
+       useless-if-before-free.
+       * top/maint.mk (VC_LIST, sc_avoid_if_before_free): Use local
+       version, rather than assuming gnulib checkout is available.
+       Reported by Simen Josefsson.
+
 2009-04-26  Bruno Haible  <address@hidden>

        Make the lib vs. lib64 recognition work on openSUSE 11 with "gcc -m32".
diff --git a/modules/maintainer-makefile b/modules/maintainer-makefile
index 492ca69..21c2802 100644
--- a/modules/maintainer-makefile
+++ b/modules/maintainer-makefile
@@ -6,6 +6,8 @@ top/maint.mk

 Depends-on:
 gnumakefile
+useless-if-before-free
+vc-list-files

 License:
 GPLed build tool
diff --git a/top/maint.mk b/top/maint.mk
index 9a683a7..229b0dc 100644
--- a/top/maint.mk
+++ b/top/maint.mk
@@ -32,7 +32,7 @@ GIT = git
 VC = $(GIT)
 VC-tag = git tag -s -m '$(VERSION)' -u '$(gpg_key_ID)'

-VC_LIST = $(gnulib_dir)/build-aux/vc-list-files -C $(srcdir)
+VC_LIST = $(srcdir)/build-aux/vc-list-files -C $(srcdir)

 VC_LIST_EXCEPT = \
   $(VC_LIST) | if test -f $(srcdir)/.x-$@; then grep -vEf $(srcdir)/.x-$@; 
else grep -v ChangeLog; fi
@@ -111,7 +111,7 @@ define _prohibit_regexp
 endef

 sc_avoid_if_before_free:
-       @$(gnulib_dir)/build-aux/useless-if-before-free                 \
+       @$(srcdir)/build-aux/useless-if-before-free                     \
                $(useless_free_options)                                 \
            $$($(VC_LIST_EXCEPT)) &&                                    \
          { echo '$(ME): found useless "if" before "free" above' 1>&2;  \
-- 
1.6.1.2


reply via email to

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