about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRicho Healey <richo@psych0tik.net>2015-04-27 23:54:30 -0700
committerRicho Healey <richo@psych0tik.net>2015-04-27 23:54:30 -0700
commitfc7faafae714e713bbe77ea6c784ae400bc0e95d (patch)
treef15a323f879cd10505142e8813dfbf11abe4d58c
parentb982a751f41c2611dff66c62a03384eafb109ed5 (diff)
downloadrust-fc7faafae714e713bbe77ea6c784ae400bc0e95d.tar.gz
rust-fc7faafae714e713bbe77ea6c784ae400bc0e95d.zip
configure: Fail iff valgrind is explicitly requested but not available
-rwxr-xr-xconfigure10
1 files changed, 8 insertions, 2 deletions
diff --git a/configure b/configure
index 5455f1b3ccf..33407bfcacd 100755
--- a/configure
+++ b/configure
@@ -737,8 +737,14 @@ fi
 # only disabled if you opt out.
 if [ -z "$CFG_VALGRIND" ]
 then
-    CFG_DISABLE_VALGRIND_RPASS=1
-    putvar CFG_DISABLE_VALGRIND_RPASS
+    # If the user has explicitly asked for valgrind tests, then fail
+    if [ -n "$CFG_ENABLE_VALGRIND" ] && [ -n "$CFG_ENABLE_VALGRIND_PROVIDED" ]
+    then
+        err "No valgrind present, but valgrind tests explicitly requested"
+    else
+        CFG_DISABLE_VALGRIND_RPASS=1
+        putvar CFG_DISABLE_VALGRIND_RPASS
+    fi
 fi
 
 if [ ! -z "$CFG_GDB" ]