Re: pgsql/src (Makefile.global.in) - Mailing list pgsql-committers

From Peter Eisentraut
Subject Re: pgsql/src (Makefile.global.in)
Date
Msg-id Pine.LNX.4.30.0012300136400.822-100000@peter.localdomain
Whole thread Raw
In response to pgsql/src (Makefile.global.in)  (tgl@postgresql.org)
Responses Re: pgsql/src (Makefile.global.in)
List pgsql-committers
tgl@postgresql.org writes:

> stamp-h needs to be made by config.status, not elsewhere, per recipe in
> Autoconf manual.

The recipe in the Autoconf manual is broken.

Assume that config.status has been updated to be newer than config.h.
Chances are that it is also newer than Makefile.global.  (Possibly because
your last cvs update fetched a new configure.)  Then the make run will
first execute config.status to update Makefile.global, which will also run
the extra commands in the second argument of AC_OUTPUT.  Thus, the stamp
file has been updated without any action taking place on config.h*.

(This is a very real scenario.  I spent quite a bit of time figuring out
why initdb in the regression test would fail after the version upgrade to
7.1beta1.  (So I guess the version cross-checking in initdb does work. :-)
)  The makefiles already got the new version (and hence the shells
scripts), but config.h didn't (and therefore not the C programs).)

> In particular, touching it before creating config.status is guaranteed
> to lose.

Exactly why?

--
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/


pgsql-committers by date:

Previous
From: petere@postgresql.org
Date:
Subject: pgsql/src (Makefile)
Next
From: tgl@postgresql.org
Date:
Subject: pgsql/src/pl/plpgsql (enable_plpgsql)