summaryrefslogtreecommitdiff
path: root/build.support/scalac.bat.template
diff options
context:
space:
mode:
Diffstat (limited to 'build.support/scalac.bat.template')
-rw-r--r--build.support/scalac.bat.template39
1 files changed, 39 insertions, 0 deletions
diff --git a/build.support/scalac.bat.template b/build.support/scalac.bat.template
new file mode 100644
index 0000000000..e2d9540439
--- /dev/null
+++ b/build.support/scalac.bat.template
@@ -0,0 +1,39 @@
+@echo off
+
+rem ##########################################################################
+rem # Copyright (C) 2002-2005 LAMP/EPFL
+rem #
+rem # This is free software; see the distribution for copying conditions.
+rem # There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
+rem # PARTICULAR PURPOSE.
+rem ##########################################################################
+
+if "%OS%"=="Windows_NT" @setlocal
+
+if "%SCALA_HOME%" == "" goto error1
+
+set _ARGS=
+:loop
+if '%1' == '' goto exec
+set _ARGS=%_ARGS% %1
+shift
+goto loop
+
+:exec
+set _JAVACMD=java
+set _PROPS=-Dscala.product=@PRODUCT@ -Dscala.version=@VERSION@
+set _MAIN=@MAIN@
+set _CPATH=@CPATH@
+
+rem echo %_JAVACMD% %_PROPS% -cp %_CPATH% %_MAIN% %_ARGS%
+%_JAVACMD% %_PROPS% -cp %_CPATH% %_MAIN% %_ARGS%
+
+rem ##########################################################################
+rem # errors
+
+:error1
+echo ERROR: environment variable SCALA_HOME is undefined. It should point to the directory containing the file %_VERSION%.
+goto end
+
+:end
+if "%OS%"=="Windows_NT" @endlocal