[libvirt] [PATCH 0/4] maint: improve bootstrap

Jim Meyering jim at meyering.net
Tue Feb 23 17:06:51 UTC 2010


Eric Blake wrote:
> My biggest motivation in writing this patch series is the fact that I
> already have the complete gnulib.git on my hard drive, and repeatedly
> doing shallow clones of gnulib into multiple projects gets expensive
> in both network traffic and disk space.  With this series, it is now
> possible to do:
>
> GNULIB_SRCDIR=/path/to/reference/gnulib.git ./autogen.sh
>
> so that the .gnulib subdirectory will exploit git's --reference
> capabilities rather than re-download all the files from scratch; it
> also results in less disk usage.  The only caveat is that you should
> make sure that your reference gnulib.git is never rewound beyond
> contents referred to by a submodule, so that you never risk creating
> delta objects in the client repositories that would break if the
> reference module eventually prunes objects rendered unused by the
> rewind (in practice, this is only a problem if you are prone to
> pointing the .gnulib submodule to a non-published commit, in order to
> test out pending changes to gnulib.git, and can be avoided by doing
> your gnulib development in a different directory than in the reference
> gnulib.git that only tracks upstream).
>
>  .gitignore           |   20 +-
>  autogen.sh           |   21 +-
>  bootstrap            |  852 +++++++++++++++++++++++++++++++++++++++++++++-----
>  bootstrap.conf       |  145 +++++++++
>  build-aux/.gitignore |   12 +-
>  po/.gitignore        |   26 +-
>  po/Makevars          |   41 ---

Thanks for doing all that.
I have applied those patches and then ran
  ./autogen.sh --enable-compile-warnings=maximum && make
but it failed like this:

  Making all in po
  make[2]: Entering directory `/w/co/libvirt/po'
  make[2]: *** No rule to make target `/config.status', needed by `Makefile'.  Stop

I tracked that down to the fact that po/Makevars is now removed
(rightly so, since it's generated), and it contained the definition
of top_builddir, which when missing provokes the diagnostic above.
po/Makevars is normally included in po/Makefile.
po/Makevars is generated only when running bootstrap, but I had already
run bootstrap, and nothing about this patch would cause it to be rerun.

We could just tell people to run bootstrap manually,
or to remove the stamp file that autogen uses to detect
when rerunning it is required, but not everyone would see that email.
A more reliable approach is to update to the latest gnulib,
since that will cause bootstrap to be rerun automatically
by anyone who pulls in that change.

I propose to include the following change right after yours:
The only trick is to disable the new syntax-check for hash.h,
since it currently evokes a false-positive.

>From 7ac7a95f3956d430b99065dc9b736a6a0ddc637a Mon Sep 17 00:00:00 2001
From: Jim Meyering <meyering at redhat.com>
Date: Tue, 23 Feb 2010 17:54:32 +0100
Subject: [PATCH] build: update gnulib submodule to latest

* cfg.mk (local-checks-to-skip): Disable sc_prohibit_hash_without_use
for now, since it fails with a false-positive match.
---
 .gnulib |    2 +-
 cfg.mk  |    1 +
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/.gnulib b/.gnulib
index 11fbc57..2709233 160000
--- a/.gnulib
+++ b/.gnulib
@@ -1 +1 @@
-Subproject commit 11fbc57405a118e6ec9a3ebc19bbf5ececdae4d6
+Subproject commit 2709233ead439b582d82af48bd25e709378cda44
diff --git a/cfg.mk b/cfg.mk
index 5013e4b..17bb341 100644
--- a/cfg.mk
+++ b/cfg.mk
@@ -42,6 +42,7 @@ local-checks-to-skip =			\
   sc_obsolete_symbols			\
   sc_prohibit_S_IS_definition		\
   sc_prohibit_atoi_atof			\
+  sc_prohibit_hash_without_use		\
   sc_prohibit_jm_in_m4			\
   sc_prohibit_quote_without_use		\
   sc_prohibit_quotearg_without_use	\
--
1.7.0.367.g566c3




More information about the libvir-list mailing list