-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.xml
executable file
·113 lines (93 loc) · 3.51 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
<?xml version="1.0"?>
<!-- ======================================================================
21.05.2005 19:55:59
generic
description
Thomas
====================================================================== -->
<project name="FunctionalJava" default="all">
<description>Java (almost) Functional Programming Library</description>
<!--
Global Properties
-->
<property name="src" location="src" />
<property name="src.main" location="${src}/main" />
<property name="src.main.java" location="${src.main}/java" />
<property name="src.main.fmpp" location="${src.main}/fmpp" />
<property name="src.main.fmpp.data" location="${src.main.fmpp}/data" />
<property name="gen" location="gen" />
<property name="gen.main" location="${gen}/main" />
<property name="gen.main.fmpp" location="${gen.main}/fmpp" />
<property name="target" location="target" />
<property name="target.main" location="${target}/main" />
<property name="target.main.java" location="${target.main}/java" />
<property name="target.lib" location="${target}/lib" />
<property name="lib" location="lib" />
<!--
Tasks Definitions
-->
<taskdef name="fmpp" classpath="${lib}/fmpp.jar" classname="fmpp.tools.AntTask" />
<!--
Targets
-->
<!-- =================================
target: all
================================= -->
<target name="all" depends="jar"
description="default">
</target>
<!-- =================================
target: clean
================================= -->
<target name="clean"
description="delete all generated directory trees">
<delete dir="${gen}" />
<delete dir="${target}" />
</target>
<!-- - - - - - - - - - - - - - - - - -
target: init
- - - - - - - - - - - - - - - - - -->
<target name="init"
description="initialize">
<!-- Create the time stamp -->
<tstamp />
<!-- Create the build directory structure used by compile and precompile and jar -->
<mkdir dir="${gen.main.fmpp}" />
<mkdir dir="${target.main.java}" />
<mkdir dir="${target.lib}" />
</target>
<!-- - - - - - - - - - - - - - - - - -
target: precompile
- - - - - - - - - - - - - - - - - -->
<target name="precompile" depends="init"
description="process templates">
<fmpp
sourceRoot="${src.main.fmpp}"
outputRoot="${gen.main.fmpp}"
data="tdd(data/fmpp.tdd)"/>
</target>
<!-- =================================
target: compile
================================= -->
<target name="compile" depends="precompile"
description="compile the source">
<!-- Compile the java code from ${gen} and ${src} into ${target} -->
<javac
destdir="${target.main.java}"
target="1.6"
source="1.6">
<src path="${gen.main.fmpp}" />
<src path="${src.main.java}" />
</javac>
</target>
<!-- =================================
target: jar
================================= -->
<target name="jar" depends="compile"
description="generate the .jar file">
<!-- Put everything in ${target.main.java} into the functional.jar file -->
<jar
jarfile="${target.lib}/functional.jar"
basedir="${target.main.java}" />
</target>
</project>