summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrzysztof Daniel2012-01-03 11:29:15 (EST)
committerSami Wagiaalla2012-02-24 15:12:58 (EST)
commit1ed0c8b36c2b4512fbdfc78948010c57a7b0531b (patch)
tree080a18d296d436c715420c0770ca7ff5d8d3878c
parent5138ae8bab40348c42386fb4639e363467dbc256 (diff)
downloadorg.eclipse.linuxtools.eclipse-build-1ed0c8b36c2b4512fbdfc78948010c57a7b0531b.zip
org.eclipse.linuxtools.eclipse-build-1ed0c8b36c2b4512fbdfc78948010c57a7b0531b.tar.gz
org.eclipse.linuxtools.eclipse-build-1ed0c8b36c2b4512fbdfc78948010c57a7b0531b.tar.bz2
Verify if the JAVA_HOME is set before build starts
A check if JAVA_HOME is set and points to an existing directory.
-rw-r--r--eclipse-build/build.xml10
1 files changed, 10 insertions, 0 deletions
diff --git a/eclipse-build/build.xml b/eclipse-build/build.xml
index 51123e9..41e3e49 100644
--- a/eclipse-build/build.xml
+++ b/eclipse-build/build.xml
@@ -4,6 +4,16 @@
</tstamp>
<record name="build_${timestamp}.log" />
<echo message="Build log is available in build_${timestamp}.log" />
+
+ <property environment="env"/>
+ <property name="jhome" value="${env.JAVA_HOME}"/>
+ <condition property="javaHomeDoesNotExists">
+ <resourceexists>
+ <file file="${jhome}"/>
+ </resourceexists>
+ </condition>
+ <fail unless="javaHomeDoesNotExists" message="JAVA_HOME is not set properly"/>
+
<property name="baseBuilder" value="${basedir}/bootstrap" />
<property name="launcher" value="${basedir}/bootstrap/plugins/org.eclipse.equinox.launcher.jar" />
<property name="eclipse.pdebuild.scripts" value="${basedir}/bootstrap/plugins/org.eclipse.pde.build/scripts" />