This repository has been archived by the owner on Jun 25, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 87
/
build.xml
186 lines (163 loc) · 5.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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
<?xml version="1.0" encoding="UTF-8"?>
<project name="turnserver" basedir="." default="rebuild">
<property name="dest" value="classes"/>
<property name="dest-test" value="classes-test"/>
<property name="lib" value="lib"/>
<property name="src" value="src"/>
<property name="test" value="test"/>
<property name="cmd.args" value="0.0.0.0 3487"/>
<property name="turnserver.jar" value="turnserver.jar"/>
<property name="doc" value="doc"/>
<property name="java.doc" value="${doc}/api"/>
<path id="project.class.path">
<pathelement location="${dest}"/>
<pathelement location="${lib}/jain-sdp.jar"/>
<pathelement location="${lib}/weupnp-0.1.2-SNAPSHOT.jar"/>
<pathelement location="${lib}/ice4j.jar"/>
<!-- <pathelement location="G:\\myPoject\ice4jProj\ice4j-read-only\\ice4j.jar"/> -->
</path>
<path id="test.class.path">
<path refid="project.class.path" />
<pathelement location="${dest-test}"/>
</path>
<!--Patternset to exclude files from the output directory:-->
<patternset id="dest.exclude">
<exclude name="package cache/"/>
<exclude name="dependency cache/"/>
</patternset>
<!-- ANT TARGETS -->
<!-- compiles all classes -->
<target name="compile" depends="init">
<javac classpathref="project.class.path"
debug="true"
deprecation="true"
destdir="${dest}"
nowarn="false"
optimize="true"
target="1.5"
source="1.5"
includeantruntime="false">
<src path="${src}"/>
<compilerarg value="-Xlint"/>
</javac>
</target>
<!-- compiles all tests -->
<target name="compile-tests" depends="init">
<javac classpathref="test.class.path"
debug="true"
deprecation="true"
destdir="${dest-test}"
nowarn="false"
optimize="true"
target="1.5"
source="1.5">
<src path="${test}"/>
<compilerarg value="-Xlint"/>
</javac>
</target>
<!-- copies ressource files if any to the classes directory -->
<target name="resource">
<copy todir="${dest}">
<fileset dir="${src}">
<include name="**/*.jpe"/>
<include name="**/*.jpeg"/>
<include name="**/*.rmf"/>
<include name="**/*.wav"/>
<include name="**/*.mid"/>
<include name="**/*.midi"/>
<include name="**/*.au"/>
<include name="**/*.gif"/>
<include name="**/*.png"/>
<include name="**/*.jpg"/>
<include name="**/*.aiff"/>
<include name="**/*.properties"/>
</fileset>
</copy>
</target>
<!-- creates the javadocs -->
<target name="javadoc">
<javadoc author="true" destdir="${java.doc}" package="true">
<fileset dir="${src}"/>
</javadoc>
</target>
<!-- delete the contents of the classes directory-->
<target name="clean">
<delete failonerror="false" includeemptydirs="true">
<fileset dir="${dest}"/>
<fileset dir="${dest-test}"/>
<fileset dir="doc" />
</delete>
<delete file="${turnserver.jar}" failonerror="true" quiet="false"/>
</target>
<!-- make everything -->
<target name="make" depends="compile,resource,jar"/>
<!-- clean and make everything -->
<target name="rebuild" depends="clean,make" />
<!-- make javadoc -->
<target name="doc" depends="make,javadoc" />
<!-- create needed subdirs-->
<target name="init">
<mkdir dir="${dest}"/>
<mkdir dir="${dest-test}"/>
</target>
<!-- create jar file-->
<target name="jar" depends="compile">
<jar compress="true" destfile="${turnserver.jar}">
<fileset dir="${dest}">
<patternset refid="dest.exclude"/>
<include name="**/*.*"/>
</fileset>
</jar>
</target>
<!-- runs our Turn Server -->
<target name="turn-server" depends="rebuild">
<java fork="true"
classname="org.jitsi.turnserver.stack.TurnServer"
classpathref="project.class.path">
<arg line="cmd.args" />
<!-- Tell java.util.logging about our logging preferences -->
<sysproperty key="java.util.logging.config.file"
value="lib/logging.properties"/>
</java>
</target>
<!-- runs our Turn Client -->
<target name="turn-udp-client">
<java fork="true"
classname="org.jitsi.turnserver.turnClient.TurnAllocationClient"
classpathref="project.class.path">
<!-- Tell java.util.logging about our logging preferences -->
<sysproperty key="java.util.logging.config.file"
value="lib/logging.properties"/>
</java>
</target>
<!-- runs our Turn Tcp Client -->
<target name="turn-tcp-client">
<java fork="true"
classname="org.jitsi.turnserver.turnClient.TurnTcpAllocationClient"
classpathref="project.class.path">
<!-- Tell java.util.logging about our logging preferences -->
<sysproperty key="java.util.logging.config.file"
value="lib/logging.properties"/>
</java>
</target>
<!-- runs our Turn Tcp Peer -->
<target name="turn-tcp-peer">
<java fork="true"
classname="org.jitsi.turnserver.turnClient.TcpPeer"
classpathref="project.class.path">
<!-- Tell java.util.logging about our logging preferences -->
<sysproperty key="java.util.logging.config.file"
value="lib/logging.properties"/>
</java>
</target>
<!-- runs our ICE test class -->
<target name="test-ice">
<java fork="true"
classname="test.Ice"
classpathref="test.class.path">
<!-- Tell java.util.logging about our logging preferences -->
<sysproperty key="java.util.logging.config.file"
value="lib/logging.properties"/>
</java>
</target>
</project>