-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
49 lines (44 loc) · 1.89 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
<?xml version="1.0" encoding="ISO-8859-1"?>
<project name="BoR" basedir="." default="copy">
<property file="local.properties" />
<property name="source.dir" value="src"/>
<property name="lib.dir" value="C:\Users\Aswin\git\ev3\ev3snapshot\lib"/>
<property name="swing.dir" value="lib"/>
<property name="class.dir" value="build"/>
<property name="jar.dir" value="dist"/>
<property name="main-class" value="BoRBrick.StartBoR"/>
<property name="lejos.home" value="/home/root/lejos"/>
<property name="ev3.host" value="10.0.1.1"/>
<path id="libraries.path">
<fileset dir="${lib.dir}">
<include name="*.jar"/>
</fileset>
<fileset dir="${swing.dir}">
<include name="*.jar"/>
</fileset>
</path>
<target name="clean" description="delete old files">
<delete dir="${class.dir}"/>
<delete dir="${jar.dir}"/>
</target>
<target name="compile" description="build class files" depends="clean">
<mkdir dir="${class.dir}"/>
<javac srcdir="${source.dir}" destdir="${class.dir}">
<classpath refid="libraries.path"/>
</javac>
</target>
<target name="jar" depends="compile">
<mkdir dir="${jar.dir}"/>
<jar destfile="${jar.dir}/${ant.project.name}.jar" basedir="${class.dir}">
<manifest>
<attribute name="Main-Class" value="${main-class}"/>
<attribute name="Class-Path" value="${lejos.home}/lib/ev3classes.jar ${lejos.home}/libjna/usr/share/java/jna.jar"/>
</manifest>
</jar>
</target>
<target name="copy" depends="jar">
<scp todir="root:@${ev3.host}:/home/root/lejos/samples/" trust="true">
<fileset file="${jar.dir}/${ant.project.name}.jar"/>
</scp>
</target>
</project>