]> granicus.if.org Git - postgresql/commitdiff
Build src/test/isolation during "make" and "make install".
authorNoah Misch <noah@leadboat.com>
Thu, 23 Nov 2017 04:18:15 +0000 (20:18 -0800)
committerNoah Misch <noah@leadboat.com>
Thu, 23 Nov 2017 04:18:15 +0000 (20:18 -0800)
This hack closes a race condition in "make -j check-world" and "make -j
installcheck-world".  Back-patch to v10, before which these parallel
invocations had worse problems.

Discussion: https://postgr.es/m/20171106080752.GA1298146@rfd.leadboat.com

src/Makefile
src/test/isolation/Makefile

index 380da92c75ef4aa6c4d08ebd15b438d3af845e4d..febbcede7d0e50c79c37b9bb20c2be260dad1d1f 100644 (file)
@@ -28,6 +28,7 @@ SUBDIRS = \
        pl \
        makefiles \
        test/regress \
+       test/isolation \
        test/perl
 
 # There are too many interdependencies between the subdirectories, so
index 8eb4969e9b8219c60aca35bbb1dc46bfca621433..efbdc40e1d36497620d25f80c27922019c091477 100644 (file)
@@ -15,6 +15,13 @@ OBJS =  specparse.o isolationtester.o $(WIN32RES)
 
 all: isolationtester$(X) pg_isolation_regress$(X)
 
+# Though we don't install these binaries, build them during installation
+# (including temp-install).  Otherwise, "make -j check-world" and "make -j
+# installcheck-world" would spawn multiple, concurrent builds in this
+# directory.  Later builds would overwrite files while earlier builds are
+# reading them, causing occasional failures.
+install: | all
+
 submake-regress:
        $(MAKE) -C $(top_builddir)/src/test/regress pg_regress.o