If you just git clone, ./autogen.sh, make, then the first time you get this error: Making all in po make[2]: Entering directory `/home/rjones/d/libguestfs/po' make[2]: *** No rule to make target `/config.status', needed by `Makefile'. Stop. make[2]: Leaving directory `/home/rjones/d/libguestfs/po' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/rjones/d/libguestfs' make: *** [all] Error 2 However rerunning autogen.sh fixes it. Any ideas why? Rich. -- Richard Jones, Emerging Technologies, Red Hat http://et.redhat.com/~rjones virt-p2v converts physical machines to virtual machines. Boot with a live CD or over the network (PXE) and turn machines into Xen guests. http://et.redhat.com/~rjones/virt-p2v
On Mon, Aug 10, 2009 at 12:07:41PM +0100, Richard W.M. Jones wrote:
However rerunning autogen.sh fixes it. Any ideas why?
Actually, it's running ./bootstrap that fixes it. But I'm still not clear why since it seems like autogen should run bootstrap. Rich. -- Richard Jones, Emerging Technologies, Red Hat http://et.redhat.com/~rjones Read my programming blog: http://rwmj.wordpress.com Fedora now supports 75 OCaml packages (the OPEN alternative to F#) http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
Richard W.M. Jones wrote:
On Mon, Aug 10, 2009 at 12:07:41PM +0100, Richard W.M. Jones wrote:
However rerunning autogen.sh fixes it. Any ideas why?
Actually, it's running ./bootstrap that fixes it. But I'm still not clear why since it seems like autogen should run bootstrap.
As opposed to pulling the script into autogen.sh? Part of the reason is that typically bootstrap is much larger, e.g., http://git.sv.gnu.org/cgit/coreutils.git/tree/bootstrap I tried to extract out only the bare minimum for libguestfs. We learned via libvirt that when people use "git pull" to pull in a new snapshot of gnulib, it's important to make the usual autogen.sh script detect that and automatically take the unusual step of re-running the relatively expensive bootstrap script. Luckily, gnulib is stable enough that few projects need to update to a new version frequently.
On Mon, Aug 10, 2009 at 02:16:31PM +0200, Jim Meyering wrote:
We learned via libvirt that when people use "git pull" to pull in a new snapshot of gnulib, it's important to make the usual autogen.sh script detect that and automatically take the unusual step of re-running the relatively expensive bootstrap script.
Isn't this a similar situation to someone who does 'git clone' and then runs autogen (without running bootstrap)? I can't see why it wouldn't work now, because 'git submodule status' should produce a different result if the submodule does not exist. Or maybe I'm not understanding how that works. Rich. -- Richard Jones, Emerging Technologies, Red Hat http://et.redhat.com/~rjones libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://et.redhat.com/~rjones/libguestfs/ See what it can do: http://et.redhat.com/~rjones/libguestfs/recipes.html
Richard W.M. Jones wrote:
On Mon, Aug 10, 2009 at 02:16:31PM +0200, Jim Meyering wrote:
We learned via libvirt that when people use "git pull" to pull in a new snapshot of gnulib, it's important to make the usual autogen.sh script detect that and automatically take the unusual step of re-running the relatively expensive bootstrap script.
Isn't this a similar situation to someone who does 'git clone' and then runs autogen (without running bootstrap)?
I can't see why it wouldn't work now, because 'git submodule status' should produce a different result if the submodule does not exist. Or maybe I'm not understanding how that works.
The first autogen.sh run is special in that some files are not yet present, like po/Makevars.template, required for this (from bootstrap): # Create gettext configuration. echo "$0: Creating po/Makevars from po/Makevars.template ..." rm -f po/Makevars sed ' /^EXTRA_LOCALE_CATEGORIES *=/s/=.*/= '"$EXTRA_LOCALE_CATEGORIES"'/ /^MSGID_BUGS_ADDRESS *=/s/=.*/= '"$MSGID_BUGS_ADDRESS"'/ /^XGETTEXT_OPTIONS *=/{ s/$/ \\/ a\ '"$XGETTEXT_OPTIONS"' $${end_of_xgettext_options+} } ' po/Makevars.template >po/Makevars Normally, po/Makevars.template is created when autoreconf invokes autopoint, but autoreconf has to be run *after* bootstrap pulls in .m4 and .am snippets from gnulib. The solution is to run autopoint *before* bootstrap. I've just confirmed that this patch solves the problem: diff --git a/bootstrap b/bootstrap index 1eee72d..cea8c40 100755 --- a/bootstrap +++ b/bootstrap @@ -28,6 +28,9 @@ GNULIB_SRCDIR=.gnulib ls po/*.po 2>/dev/null | sed 's|.*/||; s|\.po$||' > po/LINGUAS +# Run autopoint, to get po/Makevars.template: +autopoint + # Create gettext configuration. echo "$0: Creating po/Makevars from po/Makevars.template ..." rm -f po/Makevars
On Mon, Aug 10, 2009 at 02:58:57PM +0200, Jim Meyering wrote:
diff --git a/bootstrap b/bootstrap index 1eee72d..cea8c40 100755 --- a/bootstrap +++ b/bootstrap @@ -28,6 +28,9 @@ GNULIB_SRCDIR=.gnulib
ls po/*.po 2>/dev/null | sed 's|.*/||; s|\.po$||' > po/LINGUAS
+# Run autopoint, to get po/Makevars.template: +autopoint + # Create gettext configuration. echo "$0: Creating po/Makevars from po/Makevars.template ..." rm -f po/Makevars
Sure, ACK. Rich. -- Richard Jones, Emerging Technologies, Red Hat http://et.redhat.com/~rjones libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://et.redhat.com/~rjones/libguestfs/ See what it can do: http://et.redhat.com/~rjones/libguestfs/recipes.html
Richard W.M. Jones wrote:
On Mon, Aug 10, 2009 at 02:58:57PM +0200, Jim Meyering wrote:
diff --git a/bootstrap b/bootstrap index 1eee72d..cea8c40 100755 --- a/bootstrap +++ b/bootstrap @@ -28,6 +28,9 @@ GNULIB_SRCDIR=.gnulib
ls po/*.po 2>/dev/null | sed 's|.*/||; s|\.po$||' > po/LINGUAS
+# Run autopoint, to get po/Makevars.template: +autopoint + # Create gettext configuration. echo "$0: Creating po/Makevars from po/Makevars.template ..." rm -f po/Makevars
Sure, ACK.
ok. pushed
Richard W.M. Jones wrote:
If you just git clone, ./autogen.sh, make, then the first time you get this error:
Making all in po make[2]: Entering directory `/home/rjones/d/libguestfs/po' make[2]: *** No rule to make target `/config.status', needed by `Makefile'. Stop. make[2]: Leaving directory `/home/rjones/d/libguestfs/po' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/home/rjones/d/libguestfs' make: *** [all] Error 2
However rerunning autogen.sh fixes it. Any ideas why?
Thanks! It's because bootstrap's use of po/Makevars.template must happen only after autopoint, which creates that file. I'm writing the fix now.
participants (2)
-
Jim Meyering -
Richard W.M. Jones