aboutsummaryrefslogtreecommitdiffstats
path: root/layoutopt
diff options
context:
space:
mode:
authorRaphael Moll <raphael@google.com>2010-01-28 15:09:49 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2010-01-28 15:09:49 -0800
commit1b55b0e1dafade9d3fe2aec76dfef21120461e2e (patch)
treee6c4eec112f52f206b7992d1275a4be39b623d51 /layoutopt
parent7f936905578addde9df683dd27e4371beced9549 (diff)
parent176573bfeb4c68d877a9de7f17a2ab33ddfb343f (diff)
downloadsdk-1b55b0e1dafade9d3fe2aec76dfef21120461e2e.zip
sdk-1b55b0e1dafade9d3fe2aec76dfef21120461e2e.tar.gz
sdk-1b55b0e1dafade9d3fe2aec76dfef21120461e2e.tar.bz2
am 176573bf: am 912fa771: Merge "Windows SDK: use find_java.bat in all batch wrappers." into eclair
Merge commit '176573bfeb4c68d877a9de7f17a2ab33ddfb343f' * commit '176573bfeb4c68d877a9de7f17a2ab33ddfb343f': Windows SDK: use find_java.bat in all batch wrappers.
Diffstat (limited to 'layoutopt')
-rwxr-xr-xlayoutopt/app/etc/layoutopt.bat7
1 files changed, 6 insertions, 1 deletions
diff --git a/layoutopt/app/etc/layoutopt.bat b/layoutopt/app/etc/layoutopt.bat
index a7e6ade..7fedf31 100755
--- a/layoutopt/app/etc/layoutopt.bat
+++ b/layoutopt/app/etc/layoutopt.bat
@@ -24,6 +24,11 @@ rem Change current directory and drive to where the script is, to avoid
rem issues with directories containing whitespaces.
cd /d %~dp0
+rem Check we have a valid Java.exe in the path.
+set java_exe=
+call find_java.bat
+if not defined java_exe goto :EOF
+
set jarfile=layoutopt.jar
set frameworkdir=
@@ -44,5 +49,5 @@ set jarpath=%frameworkdir%%jarfile%
set javaextdirs=%swt_path%;%frameworkdir%
-call java %java_debug% -Djava.ext.dirs=%javaextdirs% -jar %jarpath% %*
+call %java_exe% %java_debug% -Djava.ext.dirs=%javaextdirs% -jar %jarpath% %*