Index: tests/Makefile.am
===================================================================
--- tests/Makefile.am	(revision 58b6d1b3b8da710a22441043f60cb988a2c2e56d)
+++ tests/Makefile.am	(revision a5121bff2d239413034fc4cc466f9e5b15eebd1b)
@@ -31,8 +31,7 @@
 	-Wno-unused-function \
 	-quiet @CFA_FLAGS@ \
-	-DIN_DIR="${srcdir}/.in/" \
-	@BUILD_IN_TREE_FLAGS@
+	-DIN_DIR="${srcdir}/.in/"
 
-AM_CFLAGS += ${DEBUG_FLAGS}
+AM_CFLAGS += ${DEBUG_FLAGS} ${INSTALL_FLAGS}
 
 CC = @CFACC@
@@ -48,8 +47,8 @@
 #----------------------------------------------------------------------------------------------------------------
 all-local :
-	@+${TEST_PY} --debug=${debug} ${concurrent} ${quick_test}
+	@+${TEST_PY} --debug=${debug}  --install=${installed} ${concurrent} ${quick_test}
 
 all-tests :
-	@+${TEST_PY} --all --debug=${debug} ${concurrent}		# '@' => do not echo command (SILENT), '+' => allows recursive make from within python program
+	@+${TEST_PY} --all --debug=${debug}  --install=${installed} ${concurrent}		# '@' => do not echo command (SILENT), '+' => allows recursive make from within python program
 
 clean-local :
@@ -66,5 +65,5 @@
 
 concurrency :
-	@+${TEST_PY} --debug=${debug} -Iconcurrent
+	@+${TEST_PY} --debug=${debug}  --install=${installed} -Iconcurrent
 
 #----------------------------------------------------------------------------------------------------------------
Index: tests/Makefile.in
===================================================================
--- tests/Makefile.in	(revision 58b6d1b3b8da710a22441043f60cb988a2c2e56d)
+++ tests/Makefile.in	(revision a5121bff2d239413034fc4cc466f9e5b15eebd1b)
@@ -303,6 +303,6 @@
 # applies to both programs
 AM_CFLAGS = $(if $(test), 2> $(test), ) -g -Wall -Wno-unused-function \
-	-quiet @CFA_FLAGS@ -DIN_DIR="${srcdir}/.in/" \
-	@BUILD_IN_TREE_FLAGS@ ${DEBUG_FLAGS}
+	-quiet @CFA_FLAGS@ -DIN_DIR="${srcdir}/.in/" ${DEBUG_FLAGS} \
+	${INSTALL_FLAGS}
 fstream_test_SOURCES = fstream_test.c
 avl_test_SOURCES = avltree/avl_test.c avltree/avl0.c avltree/avl1.c avltree/avl2.c avltree/avl3.c avltree/avl4.c avltree/avl-private.c
@@ -613,8 +613,8 @@
 #----------------------------------------------------------------------------------------------------------------
 all-local :
-	@+${TEST_PY} --debug=${debug} ${concurrent} ${quick_test}
+	@+${TEST_PY} --debug=${debug}  --install=${installed} ${concurrent} ${quick_test}
 
 all-tests :
-	@+${TEST_PY} --all --debug=${debug} ${concurrent}		# '@' => do not echo command (SILENT), '+' => allows recursive make from within python program
+	@+${TEST_PY} --all --debug=${debug}  --install=${installed} ${concurrent}		# '@' => do not echo command (SILENT), '+' => allows recursive make from within python program
 
 clean-local :
@@ -631,5 +631,5 @@
 
 concurrency :
-	@+${TEST_PY} --debug=${debug} -Iconcurrent
+	@+${TEST_PY} --debug=${debug}  --install=${installed} -Iconcurrent
 
 #----------------------------------------------------------------------------------------------------------------
Index: tests/pybin/settings.py
===================================================================
--- tests/pybin/settings.py	(revision 58b6d1b3b8da710a22441043f60cb988a2c2e56d)
+++ tests/pybin/settings.py	(revision a5121bff2d239413034fc4cc466f9e5b15eebd1b)
@@ -67,4 +67,9 @@
 		self.flags  = """DEBUG_FLAGS="%s" """ % ("-debug" if value else "-nodebug")
 
+class Install:
+	def __init__(self, value):
+		self.string = "installed" if value else "in-tree"
+		self.flags  = """INSTALL_FLAGS="%s" """ % ("" if value else "-in-tree")
+
 def init( options ):
 	global arch
@@ -73,5 +78,5 @@
 	global make
 	global debug
-	global debugFlag
+	global install
 
 	dry_run    = options.dry_run
@@ -79,4 +84,5 @@
 	make       = 'make'
 	debug	     = Debug(options.debug)
+	install    = Install(options.install)
 	arch       = Architecture(options.arch)
 
Index: tests/pybin/tools.py
===================================================================
--- tests/pybin/tools.py	(revision 58b6d1b3b8da710a22441043f60cb988a2c2e56d)
+++ tests/pybin/tools.py	(revision a5121bff2d239413034fc4cc466f9e5b15eebd1b)
@@ -102,4 +102,5 @@
 		test_param,
 		settings.debug.flags,
+		settings.install.flags,
 		flags,
 		target,
Index: tests/test.py
===================================================================
--- tests/test.py	(revision 58b6d1b3b8da710a22441043f60cb988a2c2e56d)
+++ tests/test.py	(revision a5121bff2d239413034fc4cc466f9e5b15eebd1b)
@@ -86,4 +86,5 @@
 	parser = argparse.ArgumentParser(description='Script which runs cforall tests')
 	parser.add_argument('--debug', help='Run all tests in debug or release', type=yes_no, default='yes')
+	parser.add_argument('--install', help='Run all tests based on installed binaries or tree binaries', type=yes_no, default='no')
 	parser.add_argument('--arch', help='Test for specific architecture', type=str, default='')
 	parser.add_argument('--dry-run', help='Don\'t run the tests, only output the commands', action='store_true')
