Building PostgreSQL outside the source tree is slightly broken:

(Using the current CVS HEAD code)

$ mkdir ~/test-pg-build
$ cd ~/test-pg-build
$ ../pgsql/configure
[ output omitted]
$ make
[ output omitted; make succeeds ]
$ touch ../pgsql/configure     # i.e. cvs up
$ make

The final make command invokes 'config.status --recheck', which
invokes '../pgsql/configure --no-create --no-recursion'. The re-run of
configure succeeds, but the rest of the make fails abruptly:

make: *** No rule to make target `src/Makefile.global.in', needed by
`src/Makefile.global'.  Stop.

When 'configure' has been updated, we use config.status to re-run
configure with the arguments that were previously specified. The
problem is caused by the '--no-create' flag passed to configure by
config.status: in configure.in we don't set the 'vpath_build' variable
if '--no-create' has been specified. 

(Therefore, when src/Makefile.global is recreated after configure is
re-run, the 'vpath_build' variable isn't set, and a vpath build
(i.e. a build outside the source tree) obviously fails.)

Any comments on how we should fix this?

-Neil


Wed, 26 Nov 2003 12:14:59 -0500
Neil Conway <neilc@samurai.com>
building outside source tree
Neil Conway writes:

> Building PostgreSQL outside the source tree is slightly broken:

I've installed a patch that should fix this.

-- 
Peter Eisentraut   peter_e@gmx.net


Thu, 27 Nov 2003 19:17:14 +0100 (CET)
Peter Eisentraut <peter_e@gmx.net>
Re: building outside source tree