]> git.ipfire.org Git - thirdparty/libvirt.git/commit
build: improve check for out-of-date .gnulib submodule
authorEric Blake <eblake@redhat.com>
Fri, 2 Apr 2010 20:52:35 +0000 (14:52 -0600)
committerEric Blake <eblake@redhat.com>
Fri, 2 Apr 2010 21:49:32 +0000 (15:49 -0600)
commitd002c250cd3a06e430eeda46a745b31900017812
treeb3ef11c73cb0eaaaef96d041d581601c03ba3473
parent8d30e5f74d51bf3db605f2544b5a48e5dd483a55
build: improve check for out-of-date .gnulib submodule

git reset --hard 96e5a2d4d5b13bf2cc887562dc11d146b78d5950
./autogen.sh
make -s
git pull
make -s    <-- expecting auto-bootstrap here, doesn't happen

Use git diff to expose whether the submodule has untracked changes,
which are typical on an incremental pull if .gnulib was updated but
the user did not manually run 'git submodule update'.

After this patch is applied, I encountered a new problem when
following the reproducing pattern.  Basically, the change to .gnulib
between libvirt's commit 96e5a2d4 and this patch introduced a change
to sys_ioctl.in.h, but gnulib (intentionally) does not make the
replacement headers depend on Makefile changes.  Therefore, I ended up
with the generated replacement header being broken:
gnulib/lib/sys/ioctl.h complained about a use of @.  But that seems
like something that should be fixed upstream in gnulib's bootstrap
script (that is, when doing a gnulib update, all files created from
.in.h file should probably be deleted).  Without the benefit of that
proposed gnulib fix, I worked around the problem by manually removing
the stale gnulib/lib/sys/ioctl.h.

* autogen.sh (t): Also run bootstrap if the gnulib submodule needs
to be updated.
* cfg.mk (_autogen): Likewise.
Reported by Matthias Bolte.
autogen.sh
cfg.mk