aboutsummaryrefslogtreecommitdiff
path: root/make-distribution.sh
diff options
context:
space:
mode:
authorNick Lanham <nick@afternight.org>2014-03-28 13:33:35 -0700
committerMatei Zaharia <matei@databricks.com>2014-03-28 13:33:35 -0700
commit75d46be5d61fb92a6db2efb9e3a690716ef521d3 (patch)
treeec95527e027e34c71b6e954e60e861383250effa /make-distribution.sh
parent60abc252545ec7a5d59957a32e764cd18f6c16b4 (diff)
downloadspark-75d46be5d61fb92a6db2efb9e3a690716ef521d3.tar.gz
spark-75d46be5d61fb92a6db2efb9e3a690716ef521d3.tar.bz2
spark-75d46be5d61fb92a6db2efb9e3a690716ef521d3.zip
fix path for jar, make sed actually work on OSX
Author: Nick Lanham <nick@afternight.org> Closes #264 from nicklan/make-distribution-fixes and squashes the following commits: 172b981 [Nick Lanham] fix path for jar, make sed actually work on OSX
Diffstat (limited to 'make-distribution.sh')
-rwxr-xr-xmake-distribution.sh7
1 files changed, 3 insertions, 4 deletions
diff --git a/make-distribution.sh b/make-distribution.sh
index b07aef2ef4..5c780fcbda 100755
--- a/make-distribution.sh
+++ b/make-distribution.sh
@@ -141,12 +141,11 @@ if [ "$SPARK_TACHYON" == "true" ]; then
cp -r "tachyon-${TACHYON_VERSION}"/src/main/java/tachyon/web/resources "$DISTDIR/tachyon/src/main/java/tachyon/web"
if [[ `uname -a` == Darwin* ]]; then
- # osx sed wants an empty argument to -i option of sed
- TACHYON_SED="sed -i ''"
+ # need to run sed differently on osx
+ nl=$'\n'; sed -i "" -e "s|export TACHYON_JAR=\$TACHYON_HOME/target/\(.*\)|# This is set for spark's make-distribution\\$nl export TACHYON_JAR=\$TACHYON_HOME/../jars/\1|" "$DISTDIR/tachyon/libexec/tachyon-config.sh"
else
- TACHYON_SED="sed -i"
+ sed -i "s|export TACHYON_JAR=\$TACHYON_HOME/target/\(.*\)|# This is set for spark's make-distribution\n export TACHYON_JAR=\$TACHYON_HOME/../jars/\1|" "$DISTDIR/tachyon/libexec/tachyon-config.sh"
fi
- $TACHYON_SED -e "s|export TACHYON_JAR=\$TACHYON_HOME/target/\(.*\)|# This is set for spark's make-distribution\n export TACHYON_JAR=\$TACHYON_HOME/../../jars/\1|" "$DISTDIR/tachyon/libexec/tachyon-config.sh"
popd > /dev/null
rm -rf $TMPD