-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.xml
70 lines (53 loc) · 2.11 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
<?xml version="1.0" encoding="UTF-8"?>
<project name="Drunken Bus" default="build">
<property name="preloader.class" value="net.noiseinstitute.drunkenbus.Preloader"/>
<property name="main.class" value="net.noiseinstitute.drunkenbus.Main"/>
<property name="minimum.ant.version" value="1.8.0"/>
<property environment="env"/>
<property name="FLEX_HOME" location="${env.FLEX_HOME}"/>
<property name="src.dir" location="src"/>
<property name="lib.dir" location="lib"/>
<property name="build.dir" location="build"/>
<property name="lib.flextasks" location="${lib.dir}/flexTasks.jar"/>
<property name="lib.flashpunk.dir" location="${lib.dir}/flashpunk"/>
<antversion property="ant.version.sufficient"
atleast="${minimum.ant.version}"/>
<fail unless="ant.version.sufficient">
Ant ${minimum.ant.version} is required
</fail>
<fail message='Flex not found.



You must set either the environment variable "FLEX_HOME"

or the Ant property "FLEX_HOME" to the directory where the Flex

SDK is installed.



For example: ant -DFLEX_HOME=C:\Flex
'>
<condition>
<not>
<available file="${FLEX_HOME}" type="dir"/>
</not>
</condition>
</fail>
<taskdef resource="flexTasks.tasks" classpath="${lib.flextasks}"/>
<target name="clean">
<delete dir="${build.dir}"/>
</target>
<target name="build">
<pathconvert property="preloader.file">
<mapper>
<unpackagemapper from="${src.dir}/*" to="${src.dir}/*.as"
handledirsep="true"/>
</mapper>
<path path="${src.dir}/${preloader.class}"/>
</pathconvert>
<mxmlc file="${preloader.file}"
output="${build.dir}/Release.swf"
debug="false" strict="true">
<load-config filename="${FLEX_HOME}/frameworks/flex-config.xml"/>
<source-path path-element="${src.dir}"/>
<source-path path-element="${lib.flashpunk.dir}"/>
<source-path path-element="${FLEX_HOME}/frameworks"/>
<frame label="start" className="${main.class}"/>
</mxmlc>
</target>
</project>