about summary refs log tree commit diff
diff options
context:
space:
mode:
authorErick Tryzelaar <erick.tryzelaar@gmail.com>2014-11-30 19:51:52 -0800
committerErick Tryzelaar <erick.tryzelaar@gmail.com>2014-12-03 14:40:33 -0800
commit98f01f1f5481f12796d2c7b57f36e998b1e644f0 (patch)
tree7b146cf57cc5569b7c5a8594e404839de05bd13b
parent3b4ad726f1d9982a91693e36bfce51b1013f16c4 (diff)
downloadrust-98f01f1f5481f12796d2c7b57f36e998b1e644f0.tar.gz
rust-98f01f1f5481f12796d2c7b57f36e998b1e644f0.zip
rustup: probe for the existance of tar
-rwxr-xr-xsrc/etc/rustup.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/etc/rustup.sh b/src/etc/rustup.sh
index f73a0248c85..52489412071 100755
--- a/src/etc/rustup.sh
+++ b/src/etc/rustup.sh
@@ -230,6 +230,7 @@ validate_opt() {
 }
 
 probe_need CFG_CURL  curl
+probe_need CFG_TAR   tar
 
 CFG_SRC_DIR="$(cd $(dirname $0) && pwd)/"
 CFG_SELF="$0"
@@ -430,7 +431,7 @@ if [ -z "${CFG_DISABLE_CARGO}" ]; then
 fi
 
 
-(cd "${TMP_DIR}" && tar xzf "${TARBALL_NAME}")
+(cd "${TMP_DIR}" && ${CFG_TAR} xzf "${TARBALL_NAME}")
 if [ $? -ne 0 ]
 then
         rm -Rf "${TMP_DIR}"
@@ -457,7 +458,7 @@ then
 fi
 
 if [ -z "${CFG_DISABLE_CARGO}" ]; then
-    (cd "${TMP_DIR}" && tar xzf "${CARGO_TARBALL_NAME}")
+    (cd "${TMP_DIR}" && ${CFG_TAR} xzf "${CARGO_TARBALL_NAME}")
     if [ $? -ne 0 ]
     then
             rm -Rf "${TMP_DIR}"