-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.xml
85 lines (69 loc) · 2.41 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
<project name="PEPR" default="dist" basedir=".">
<description>
simple example build file
</description>
<!-- set global properties for this build -->
<property name="src" location="src"/>
<property name="build" location="build"/>
<property name="dist" location="dist"/>
<property name="bin" location="pepr-bin"/>
<property name="lib" location="lib"/>
<property name="scripts" location="scripts"/>
<path id="project.classpath">
<fileset dir="lib" includes="*.jar" />
</path>
<target name="init">
<!-- Create the time stamp -->
<tstamp/>
<!-- Create the build directory structure used by compile -->
<mkdir dir="${build}"/>
</target>
<target name="compile" depends="init"
description="compile the source " >
<!-- Compile the java code from ${src} into ${build} -->
<javac debug="true" srcdir="${src}" classpathref="project.classpath" destdir="${build}"/>
</target>
<target name="dist" depends="compile"
description="generate the distribution" >
<!-- Create the distribution directory -->
<mkdir dir="${dist}/pepr/lib"/>
<!-- unzip any jar files in the lib directory, and put the contents in -->
<!-- the build directory so they will be packed into the distribution jar file-->
<unzip dest="${build}">
<fileset dir="lib" includes="*.jar" />
</unzip>
<copy file="BLOSUM62" todir="${build}"/>
<!-- Put everything in ${build} into the pepr.jar file -->
<jar jarfile="${dist}/pepr/lib/pepr.jar" basedir="${build}"/>
<!-- copy everything to dist directory for tar -->
<!--
<copy todir="${dist}/pepr/bin_mac">
<fileset dir="${bin}_mac"/>
</copy>
-->
<exec executable="cp">
<arg line="-R ${bin}_mac ${dist}/pepr/bin_mac"/>
</exec>
<exec executable="cp">
<arg line="-R ${bin}_linux ${dist}/pepr/bin"/>
</exec>
<!--
<copy todir="${dist}/pepr/bin">
<fileset dir="${bin}_linux"/>
</copy>
-->
<copy todir="${dist}/pepr/lib">
<fileset dir="${lib}"/>
</copy>
<copy todir="${dist}/pepr/scripts">
<fileset dir="${scripts}"/>
</copy>
<tar compression="gzip" destfile="pepr-${DSTAMP}.tar" basedir="${dist}"/>
</target>
<target name="clean"
description="clean up" >
<!-- Delete the ${build} and ${dist} directory trees -->
<delete dir="${build}"/>
<delete dir="${dist}"/>
</target>
</project>