diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2011-08-24 15:16:17 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2011-08-24 15:16:50 -0400 |
commit | d1d388603e4f9233d3e01847405b239972a54fdf (patch) | |
tree | 7706216f61ffa62f2cecf5ebdb1c8a721615848c /src/makefiles | |
parent | 4803de6f8932e2f2b96bb1243ba07a05cd2c3ae5 (diff) | |
download | postgresql-d1d388603e4f9233d3e01847405b239972a54fdf.tar.gz |
Fix pgxs.mk to always add --dbname=$(CONTRIB_TESTDB) to REGRESS_OPTS.
The previous coding resulted in contrib modules unintentionally overriding
the use of CONTRIB_TESTDB. There seems no particularly good reason to
allow that (after all, the makefile can set CONTRIB_TESTDB if that's really
what it intends).
In passing, document REGRESS_OPTS where the other pgxs.mk options are
documented.
Back-patch to 9.1 --- in prior versions, there were no cases of contrib
modules setting REGRESS_OPTS without including the --dbname switch, so
while the coding was fragile there was no actual bug.
Diffstat (limited to 'src/makefiles')
-rw-r--r-- | src/makefiles/pgxs.mk | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/makefiles/pgxs.mk b/src/makefiles/pgxs.mk index cb4dc972a8..84a296a60d 100644 --- a/src/makefiles/pgxs.mk +++ b/src/makefiles/pgxs.mk @@ -38,6 +38,7 @@ # SCRIPTS_built -- script files (not binaries) to install into $PREFIX/bin, # which need to be built first # REGRESS -- list of regression test cases (without suffix) +# REGRESS_OPTS -- additional switches to pass to pg_regress # EXTRA_CLEAN -- extra files to remove in 'make clean' # PG_CPPFLAGS -- will be added to CPPFLAGS # PG_LIBS -- will be added to PROGRAM link line @@ -225,10 +226,8 @@ distclean maintainer-clean: clean ifdef REGRESS -# Calling makefile can set REGRESS_OPTS, but this is the default: -ifndef REGRESS_OPTS -REGRESS_OPTS = --dbname=$(CONTRIB_TESTDB) -endif +# Select database to use for running the tests +REGRESS_OPTS += --dbname=$(CONTRIB_TESTDB) # where to find psql for running the tests PSQLDIR = $(bindir) |