Repository navigation
Expand file tree
/
Copy pathbuild.xml
More file actions
91 lines (68 loc) · 2.63 KB
/
Copy pathbuild.xml
File metadata and controls
91 lines (68 loc) · 2.63 KB
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<project xmlns:ivy="antlib:org.apache.ivy.ant" name="gateplugin-python" default="dist">
<description>
Plugin for Python integration in GATE.
</description>
<property name="src" location="src" />
<property name="lib" location="lib" />
<property name="dist.dir" location="dist" />
<property name="dist.lib.dir" location="dist/lib" />
<!-- Make environment variables available -->
<property environment="env" />
<!-- If environment variable GATE_HOME is set, use it for
gate.home (unless it was already set in build.properties -->
<condition property="gate.home" value="${env.GATE_HOME}">
<isset property="env.GATE_HOME"/>
</condition>
<!-- If gate.home is not set from build.properties or the
environment variable GATE_HOME, assume that this
plugin is in GATE Developer's plugin directory -->
<property name="gate.home" location="../.." />
<property name="gate.lib" location="${gate.home}/lib" />
<property name="gate.jar" location="${gate.home}/bin/gate.jar" />
<property name="build" location="build"/>
<property environment="env"/>
<!-- Path to compile - includes gate.jar and GATE/lib/*.jar -->
<path id="gate.classpath">
<pathelement location="${gate.jar}" />
<fileset dir="${gate.lib}">
<include name="**/*.jar" />
<include name="**/*.zip" />
</fileset>
</path>
<path id="ivy.lib.path">
<fileset file="${gate.home}/build/lib/ivy.jar" />
</path>
<taskdef resource="org/apache/ivy/ant/antlib.xml"
uri="antlib:org.apache.ivy.ant"
classpathref="ivy.lib.path"/>
<target name="init">
<tstamp/>
<mkdir dir="${build}"/>
<mkdir dir="${lib}"/>
<manifest file="${build}/MANIFEST.MF">
<attribute name="Main-Class" value="gate.python.PythonGATEInstance"/>
</manifest>
</target>
<target name="compile" depends="init"
description="Compile the source">
<javac srcdir="${src}" destdir="${build}" debug="true" source="1.7" target="1.7" debuglevel="lines,vars,source">
<classpath refid="default.classpath"></classpath>
<classpath refid="gate.classpath" />
</javac>
</target>
<ivy:cachepath pathid="default.classpath" conf="default" />
<target name="dist" depends="compile,resolve"
description="Generate the distribution">
<mkdir dir="${dist.dir}" />
<mkdir dir="${dist.lib.dir}" />
<jar jarfile="gateplugin-python.jar" manifest="${build}/MANIFEST.MF" basedir="${build}" index="true">
</jar>
</target>
<target name="clean"
description="Clean up">
<delete dir="${build}"/>
</target>
<target name="resolve" description="Retrieve dependencies with ivy">
<ivy:retrieve />
</target>
</project>