Skip to content
Snippets Groups Projects
Commit a37ff0f1 authored by Josh Rosen's avatar Josh Rosen
Browse files

Add spark-tools assembly to spark-class classpath.

This allows the JavaAPICompletenessChecker to be
run with Spark 0.8+.
parent 72a601ec
No related branches found
No related tags found
No related merge requests found
...@@ -265,7 +265,7 @@ object SparkBuild extends Build { ...@@ -265,7 +265,7 @@ object SparkBuild extends Build {
def toolsSettings = sharedSettings ++ Seq( def toolsSettings = sharedSettings ++ Seq(
name := "spark-tools" name := "spark-tools"
) ) ++ assemblySettings ++ extraAssemblySettings
def bagelSettings = sharedSettings ++ Seq( def bagelSettings = sharedSettings ++ Seq(
name := "spark-bagel" name := "spark-bagel"
......
...@@ -110,8 +110,21 @@ if [ ! -f "$FWDIR/RELEASE" ]; then ...@@ -110,8 +110,21 @@ if [ ! -f "$FWDIR/RELEASE" ]; then
fi fi
fi fi
TOOLS_DIR="$FWDIR"/tools
SPARK_TOOLS_JAR=""
if [ -e "$TOOLS_DIR"/target/scala-$SCALA_VERSION/*assembly*[0-9Tg].jar ]; then
# Use the JAR from the SBT build
export SPARK_TOOLS_JAR=`ls "$TOOLS_DIR"/target/scala-$SCALA_VERSION/*assembly*[0-9Tg].jar`
fi
if [ -e "$TOOLS_DIR"/target/spark-tools*[0-9Tg].jar ]; then
# Use the JAR from the Maven build
# TODO: this also needs to become an assembly!
export SPARK_TOOLS_JAR=`ls "$TOOLS_DIR"/target/spark-tools*[0-9Tg].jar`
fi
# Compute classpath using external script # Compute classpath using external script
CLASSPATH=`$FWDIR/bin/compute-classpath.sh` CLASSPATH=`$FWDIR/bin/compute-classpath.sh`
CLASSPATH="$SPARK_TOOLS_JAR:$CLASSPATH"
export CLASSPATH export CLASSPATH
if [ "$SPARK_PRINT_LAUNCH_COMMAND" == "1" ]; then if [ "$SPARK_PRINT_LAUNCH_COMMAND" == "1" ]; then
......
...@@ -65,10 +65,17 @@ if "%FOUND_JAR%"=="0" ( ...@@ -65,10 +65,17 @@ if "%FOUND_JAR%"=="0" (
) )
:skip_build_test :skip_build_test
set TOOLS_DIR=%FWDIR%tools
set SPARK_TOOLS_JAR=
for %%d in ("%TOOLS_DIR%\target\scala-%SCALA_VERSION%\spark-tools*assembly*.jar") do (
set SPARK_TOOLS_JAR=%%d
)
rem Compute classpath using external script rem Compute classpath using external script
set DONT_PRINT_CLASSPATH=1 set DONT_PRINT_CLASSPATH=1
call "%FWDIR%bin\compute-classpath.cmd" call "%FWDIR%bin\compute-classpath.cmd"
set DONT_PRINT_CLASSPATH=0 set DONT_PRINT_CLASSPATH=0
set CLASSPATH=%SPARK_TOOLS_JAR%;%CLASSPATH%
rem Figure out where java is. rem Figure out where java is.
set RUNNER=java set RUNNER=java
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment