-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathbuild.xml
129 lines (119 loc) · 4.09 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
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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
<?xml version="1.0"?>
<project name="PathSBML" default="jar" basedir=".">
<property name="version.number" value="1.0.0" />
<property name="pathvisio.dir" value="../common-bundles" />
<property name="org.pathvisio.sbgn.dir" value="../org.pathvisio.sbgn" />
<property name="common.bundles" value="../common-bundles" />
<import file="${common.bundles}/plugin-common.xml"/>
<!-- embedded jars are embedded in the resulting bundle -->
<path id="embed.jars">
<fileset dir="lib">
<include name="*.jar" />
</fileset>
<fileset dir="${common.bundles}">
<include name="org.sbgn-with-dependencies.jar" />
<include name="com.google.collect*.jar" />
<include name="com.springsource.javax.xml.rpc-1.1.0.jar" />
</fileset>
</path>
<path id="project.class.path">
<fileset dir="${pathvisio.dir}/modules">
<include name="org.pathvisio.core.jar" />
<include name="org.pathvisio.gui.jar" />
<include name="org.pathvisio.desktop.jar" />
</fileset>
<fileset dir="${common.bundles}">
<include name="org.sbgn-with-dependencies.jar" />
<include name="com.google.collect*.jar" />
<include name="com.springsource.javax.xml.rpc-1.1.0.jar" />
</fileset>
<fileset dir="${org.pathvisio.sbgn.dir}">
<include name="dist/org.pathvisio.sbgn.jar" />
</fileset>
<fileset dir="${pathvisio.dir}/lib">
<include name="org.bridgedb.jar" />
<include name="felix.jar" />
<include name="com.springsource.org.jdom-1.1.0.jar" />
<include name="org.pathvisio.jgoodies.forms.jar" />
<include name="javax.xml.rpc_1.1.0.v201005080400.jar"/>
</fileset>
<fileset dir="lib">
<include name="*.jar" />
</fileset>
</path>
<target name="prepare" depends ="prepare-jar-name,prepare-common">
<mkdir dir="build"/>
<mkdir dir="${bundle.dest}"/>
<mkdir dir="build/resources"/>
<copy toDir="build/resources">
<fileset dir="resources">
<include name="*"/>
</fileset>
</copy>
<copy toDir="build/lib">
<fileset dir="lib">
<include name="*.jar"/>
</fileset>
<fileset dir="${common.bundles}">
<include name="org.sbgn-with-dependencies.jar" />
<include name="com.google.collect*.jar" />
<include name="com.springsource.javax.xml.rpc-1.1.0.jar" />
</fileset>
</copy>
<fail message="Can't find ${pathvisio.dir}/modules/org.pathvisio.core.jar, please specify the path to pathvisio with -Dpathvisio.dir=....">
<condition>
<not><available file="${pathvisio.dir}/modules/org.pathvisio.core.jar"/></not>
</condition>
</fail>
</target>
<target name="clean">
<delete dir="build"/>
<delete file="${jar.name}"/>
</target>
<target name="compile" depends="prepare">
<echo>Compiling: ${jar.name}</echo>
<javac srcdir="src"
includes="**"
destdir="build"
debug="${debug.mode}"
source="1.5">
<classpath refid="project.class.path"/>
</javac>
</target>
<target name="jar" depends="compile">
<echo>Creating JAR: ${jar.name}</echo>
<jar jarfile="${jar.name}_${version.number}.jar" manifest="META-INF/MANIFEST.MF">
<fileset dir="build">
<include name="**/*"/>
</fileset>
</jar>
</target>
<target name="install" depends="jar">
<copy toDir="${bundle.dest}" flatten="true">
<fileset dir=".">
<include name="${jar.name}"/>
</fileset>
<fileset dir="lib">
<include name="*.jar" />
</fileset>
<fileset dir="${common.bundles}">
<include name="org.sbgn-with-dependencies.jar" />
<include name="com.google.collect*.jar" />
</fileset>
<fileset dir="${org.pathvisio.sbgn.dir}">
<include name="dist/org.pathvisio.sbgn.jar" />
</fileset>
<fileset dir="${pathvisio.dir}/lib">
<include name="org.bridgedb.jar" />
<include name="felix.jar" />
<include name="com.springsource.org.jdom-1.1.0.jar" />
<include name="org.pathvisio.jgoodies.forms.jar" />
<include name="javax.xml.rpc_1.1.0.v201005080400.jar"/>
</fileset>
</copy>
<delete file="${jar.name}"/>
</target>
<target name="dist-clean" depends="clean">
<delete dir="${bundle.dest}"/>
</target>
</project>