[libvirt] [PATCH 2/2] build: don't lose prior configure args on autogen.sh

Jim Meyering jim at meyering.net
Fri Mar 26 18:16:11 UTC 2010

Eric Blake wrote:

> My prior patch forced an autogen.sh run, and I was surprised that the
> suggested './autogen.sh' lost the fact that I had previously used
> './autogen.sh -C' for speed.
> * autogen.sh: Use config.status, if present and there were no arguments.

This looks fine, too.
I confirmed that it works as advertised,
and am about to push this and the preceding 1/2.

A small word of warning to our readers:

For those new to configure's -C (--cache) option,
be aware that its use comes with a responsibility (or price).
You have to be careful to remove the cache periodically,
in case something about your system or the configure-time
tests makes it so a cached result is invalid.
If you forget, and reuse an invalid cache, you can easily
end up with subtle and hard-to-diagnose bugs.

> I noticed this on the previous patch, because I blindly followed
> make's instructions to rerun ./autogen.sh, only to later realize
> that I just nuked my nice ./configure --enable-compiler-warnings=error
> settings.
> Hmm, as long as make is smart enough to warn, and now that running
> ./autogen.sh with no arguments is reliable at maintaining an
> existing setup, I could even submit a followup patch to have make
> blindly run ./autogen.sh instead of dying with the error that the
> user has to run it.  Any interest in such a followup?

I have a slight preference for automating it.

The current failure+instructions do serve to tell the user that something
unusual (and time-consuming) is about to happen, but it's easy
to print a warning to that effect while automating the job.

More information about the libvir-list mailing list