-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.xml
More file actions
76 lines (69 loc) · 2.72 KB
/
Copy pathbuild.xml
File metadata and controls
76 lines (69 loc) · 2.72 KB
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
<project name="percentjuice_as3utils" basedir="." default="create zip">
<property file="build.properties" />
<target name="properties">
<fail unless="FLEX_HOME">The "FLEX_HOME" property must be set in your global ANT properties or build.properties.</fail>
</target>
<target name="clean" description="Remove folders generated by the build.">
<echo>[clean] Removing generating folders.</echo>
<delete dir="${deploy.dir}" quiet="true" includeEmptyDirs="true"/>
<delete dir="${docs.local.dir}" quiet="true" includeEmptyDirs="true"/>
</target>
<target name="compile swc" depends="properties,clean" description="Builds library">
<echo>[swc] Building SWC</echo>
<echo>[swc] Using Flex SDK at: ${FLEX_HOME}</echo>
<echo>[swc] Using Compiler at: ${compc}</echo>
<exec executable="${compc}" dir="${basedir}" failonerror="true">
<arg line="-o '${deploy.dir}/${binary.name}.swc'" />
<arg line="-sp '${src.dir}'" />
<arg line="-is '${src.dir}'" />
<arg line="-el '${libs.dir}'" />
<arg line="-el '${playerglobal.swc}'" />
<arg line="-target-player ${target.player}" />
</exec>
</target>
<target name="generate asdoc" description="Generate documentation" depends="properties">
<mkdir dir="${docs.local.dir}"/>
<delete includeemptydirs="true">
<fileset dir="${docs.local.dir}" includes="**/*" />
</delete>
<exec executable="${asdoc}" spawn="no">
<arg line="-o '${docs.local.dir}'" />
<arg line="-l '${libs.dir}'" />
<arg line="-sp '${src.dir}'" />
<arg line="-ds '${src.dir}' " />
<arg line="-target-player ${target.player}" />
<arg line="-window-title 'Adobe ActionScript 3.0 Library - ${project.title}'" />
</exec>
</target>
<target name="create zip" description="create download zip" depends="compile swc,generate asdoc">
<mkdir dir="${deploy.dir}/zip/dependencies"/>
<mkdir dir="${deploy.dir}/zip/release"/>
<mkdir dir="${deploy.dir}/zip/docs"/>
<copy todir="${deploy.dir}/zip/release">
<fileset dir="${deploy.dir}">
<include name="*.swc"/>
</fileset>
</copy>
<copy todir="${deploy.dir}/zip/dependencies">
<fileset dir="${libs.dir}">
<include name="as3-signals-v*.swc"/>
<include name="as3-signals-utilities-async-v*.swc"/>
<include name="hamcrest-as3-only-*.swc"/>
<include name="mockito-*.swc"/>
<include name="flexunit-4*.swc"/>
<include name="flexunit-cilistener-*.swc"/>
<include name="flexunit-uilistener-*.swc"/>
</fileset>
</copy>
<copy todir="${deploy.dir}/zip/docs">
<fileset dir="${docs.local.dir}">
<include name="**"/>
</fileset>
</copy>
<zip destfile="${deploy.dir}/${binary.name}.zip">
<fileset dir="${deploy.dir}/zip" />
</zip>
<delete dir="${deploy.dir}/zip" includeemptydirs="true">
</delete>
</target>
</project>