]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
build: avoid corrupted gnulib/tests/Makefile
authorEric Blake <eblake@redhat.com>
Tue, 25 Jan 2011 00:14:19 +0000 (17:14 -0700)
committerEric Blake <eblake@redhat.com>
Tue, 25 Jan 2011 00:19:25 +0000 (17:19 -0700)
Running 'make check' can sometimes fail in the gnulib/tests
subdirectory, when doing an incremental build, because
./bootstrap generates a Makefile.am that tries to refer to
../../.. instead of ../.., and gets lost.

This may be an upstream gnulib bug, where a more elegant
solution will present itself in the future:
http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/24898

But in the meantime, I was able to reproduce both the issue,
and this solution to work around it.

* bootstrap.conf (bootstrap_epilogue): Ensure that no stray
../../.. components remain in gnulib/tests/Makefile.in.
Reported by Serge Hallyn.

bootstrap.conf

index 88832d163fe53f1c9913d6013c9b0d3e98923b2a..2c425bbfb1eb9d604f18287e1f74cc84dfcb690e 100644 (file)
@@ -168,8 +168,10 @@ touch ChangeLog || exit 1
 
 bootstrap_epilogue()
 {
-  # Change paths in gnulib/tests/Makefile.am from "../../.." to "../..".
+  # Change paths in gnulib/tests/Makefile.am from "../../.." to "../..",
+  # then ensure that gnulib/tests/Makefile.in is up-to-date.
   m=gnulib/tests/Makefile.am
   sed 's,\.\./\.\./\.\.,../..,g' $m > $m-t
   mv -f $m-t $m
+  ${AUTOMAKE-automake} gnulib/tests/Makefile
 }