-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.xml
61 lines (51 loc) · 2.05 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- WARNING: Eclipse auto-generated file.
Any modifications will be overwritten.
To include a user specific buildfile here, simply create one in the same
directory with the processing instruction <?eclipse.ant.import?>
as the first entry and export the buildfile again. -->
<project basedir="." default="makejar" name="rosmop">
<property name="target" value="1.7"/>
<property name="source" value="1.7"/>
<property environment="env"/>
<!-- <property name="rvmlib" value="${env.RVMONITOR}/lib" /> -->
<path id="rosmop.classpath">
<fileset dir="${env.RVMONITOR}" includes="**/*.jar"/>
</path>
<!--checking if for windows and non windows OS-->
<condition property="isUnix">
<os family="unix" />
</condition>
<condition property="isWindows">
<os family="windows" />
</condition>
<!-- if the OS is windows call the target run.script.windows -->
<target name="ifNotUnix" if="isWindows">
<echo>Calling parser.bat</echo>
<exec dir="bin" executable="cmd" failonerror="true">
<arg line="/c parsergen.bat"/>
</exec>
</target>
<!-- if the OS is not windows call the target run.script.unix-->
<target name="ifUnix" if="isUnix">
<echo>Calling parser</echo>
<exec executable="bin/parsergen" failonerror="true"/>
</target>
<target name="init">
<mkdir dir="classes"/>
</target>
<target name="clean">
<delete dir="classes"/>
<delete dir="lib"/>
</target>
<target depends="clean" name="cleanall"/>
<target depends="build-project" name="build"/>
<target depends="init" name="build-project">
<echo message="${ant.project.name}: ${ant.file}"/>
<javac destdir="classes" srcdir="src" source="${source}" target="${target}" includeantruntime="false" classpathref="rosmop.classpath" />
</target>
<target name="makejar" description="Create Jar file" depends="ifUnix, ifNotUnix, build">
<mkdir dir="lib" />
<jar jarfile="lib/ROSMOP.jar" basedir="classes" />
</target>
</project>