]> git.lizzy.rs Git - rust.git/commitdiff
build: Fix logic around --enable-local-rust
authorBrian Anderson <banderson@mozilla.com>
Thu, 19 Apr 2012 22:46:09 +0000 (15:46 -0700)
committerBrian Anderson <banderson@mozilla.com>
Thu, 19 Apr 2012 22:46:25 +0000 (15:46 -0700)
configure

index 06f385c1da338971b7a15620f4f409776e6a4098..513ea2614062529f12793037501d90e85d9b5ed9 100755 (executable)
--- a/configure
+++ b/configure
@@ -349,12 +349,15 @@ then
     fi
 fi
 
-if [ ! -z "$CFG_ENABLE_LOCAL_RUST" -a ! -f ${CFG_LOCAL_RUST_ROOT}/bin/rustc ]
+if [ ! -z "$CFG_ENABLE_LOCAL_RUST" ]
 then
-    err "no local rust to use"
-else
-    LRV=`${CFG_LOCAL_RUST_ROOT}/bin/rustc --version`
-    step_msg "using rustc at: ${CFG_LOCAL_RUST_ROOT} with version: " $LRV
+    if [ ! -f ${CFG_LOCAL_RUST_ROOT}/bin/rustc ]
+    then
+        err "no local rust to use"
+    else
+        LRV=`${CFG_LOCAL_RUST_ROOT}/bin/rustc --version`
+        step_msg "using rustc at: ${CFG_LOCAL_RUST_ROOT} with version: " $LRV
+    fi
 fi
 
 if [ -z "$CFG_ENABLE_CLANG" -a -z "$CFG_GCC" ]