Browse Source

[trac606] make sure distclean works for a separate builddir,
even if systest itself cannot be run for such build environment.
also added an explicit check about the assumption in conf.sh with
an error message explaining what's wrong.

JINMEI Tatuya 14 years ago
parent
commit
f3bd834c8e
3 changed files with 10 additions and 3 deletions
  1. 1 1
      Makefile.am
  2. 2 2
      tests/system/Makefile.am
  3. 7 0
      tests/system/conf.sh.in

+ 1 - 1
Makefile.am

@@ -80,7 +80,7 @@ cppcheck:
 # system tests
 systest:
 	cd tests/system; \
-	sh runall.sh
+	sh $(abs_srcdir)/tests/system/runall.sh
 
 #### include external sources in the distributed tarball:
 EXTRA_DIST = ext/asio/README

+ 2 - 2
tests/system/Makefile.am

@@ -1,5 +1,5 @@
 systest:
-	sh runall.sh
+	sh $(srcdir)/runall.sh
 
 distclean-local:
-	sh cleanall.sh
+	sh $(srcdir)/cleanall.sh

+ 7 - 0
tests/system/conf.sh.in

@@ -20,6 +20,13 @@
 # other shell scripts.
 #
 
+# Prerequisite check
+if [ @srcdir@ != @builddir@ ]; then
+	echo "Currently systest doesn't work for a separate build tree."
+	echo "Rebuild BIND 10 on the source tree and run the tests."
+	exit 1
+fi
+
 # Find the top of the source tree.
 TOP=@abs_top_srcdir@