-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.xml
More file actions
188 lines (161 loc) · 6.27 KB
/
build.xml
File metadata and controls
188 lines (161 loc) · 6.27 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
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
187
188
<?xml version="1.0" encoding="UTF-8"?>
<!-- ======================================================================
Mar 10, 2014 3:54:12 P
LinkWu
====================================================================== -->
<project default="help" basedir=".">
<description>
Flex/AS3 project template
</description>
<import file="build_setup.xml" />
<import file="build_gen.xml" />
<import file="build_ftp.xml" />
<target name="help" description="Show help message">
</target>
<target name="menu" description="Show menu">
<input message="Select the target..." validargs="clean,doc,help,build,wrap" addproperty="menu.target" defaultvalue="help" />
<antcall target="${menu.target}" />
</target>
<target name="doc" depends="setup" description="Doc all">
<asdoc output="${config.dir.ref}" package-description-file="${basedir}/package.xml" lenient="true" debug="${config.debug}" debug-password="${config.debug.password}" optimize="${config.optimize}" incremental="${config.incremental}" locale="${config.locale}" target-player="${config.player.version}" swf-version="${config.swf.version}" fork="true">
<load-config filename="${config.flex_config.file}" />
<doc-sources dir="${config.dir.src}">
<include name="**/src/*" />
</doc-sources>
<external-library-path dir="${config.dir.playerglobal}" includes="**/*.swc" append="true" />
<library-path dir="${config.dir.src}" includes="**/lib/*.swc" append="true" />
<library-path dir="${config.dir.lib}" includes="**/*.swc" append="true" />
<external-library-path dir="${config.dir.src}/" includes="**/rsl/*.swc" append="true" />
<external-library-path dir="${config.dir.rsl}/" includes="**/*.swc" append="true" />
<jvmarg line="${jvmarg.asdoc}" />
</asdoc>
</target>
<target name="select" description="Build the selected">
<input message="Please enter project name, delimit them with a comma:" addproperty="targets.name" defaultvalue="" />
<java jar="${basedir}/ext/util_order/main.jar" fork="true" failonerror="true">
<arg value="${basedir}"/>
<arg value="${targets.name}"/>
<jvmarg value="-Dfile.encoding=${file.encoding}"/>
</java>
</target>
<target name="build" description="Build all">
<java jar="${basedir}/ext/util_order/main.jar" fork="true" failonerror="true">
<arg line="${basedir}"/>
<jvmarg value="-Dfile.encoding=${file.encoding}"/>
</java>
</target>
<target name="up" depends="setup">
<antcall target="ftp_up" />
</target>
<target name="down" depends="setup">
<antcall target="ftp_down" />
</target>
<target name="wrap" depends="setup" description="Wrap all">
<antcall target="wrap_all" />
</target>
<target name="wrap_all">
<foreach param="project.dir" target="wrap_one" parallel="${config.parallel}" maxthreads="${config.maxthread}" inheritall="true">
<path>
<dirset dir="${config.dir.src}">
<depth max="0" min="0" />
</dirset>
</path>
</foreach>
</target>
<target name="wrap_one">
<basename file="${project.dir}" property="project.name" />
<if>
<and>
<available filepath="${config.dir.src}" file="${project.name}" type="dir" />
<not>
<available file="${config.dir.src}/${project.name}/.islibrary"/>
</not>
</and>
<then>
<ant dir="${config.dir.src}/${project.name}" antfile="${project.name}.xml" target="wrapper" output="${config.dir.log}/${project.name}.log" />
</then>
<else>
<echo>${config.dir.src}/${project.name} is not exist!!</echo>
<echo>${project.name} is not a runnable project!!</echo>
</else>
</if>
</target>
<target name="clean" depends="setup" description="Clean all">
<antcall target="clean_bin" />
<antcall target="clean_log" />
<antcall target="clean_ref" />
<antcall target="clean_src" />
</target>
<target name="clean_bin">
<delete includeemptydirs="true" verbose="true">
<fileset dir="${config.dir.bin}">
<exclude name=".gitkeep" />
<include name="**/*" />
</fileset>
</delete>
</target>
<target name="clean_log">
<delete deleteonexit="true" includeemptydirs="true" verbose="true">
<fileset dir="${config.dir.log}">
<exclude name=".gitkeep" />
<include name="**/*" />
</fileset>
</delete>
</target>
<target name="clean_ref">
<delete includeemptydirs="true" verbose="true">
<fileset dir="${config.dir.ref}">
<exclude name=".gitkeep" />
<include name="**/*" />
</fileset>
</delete>
</target>
<target name="clean_src">
<delete includeemptydirs="true" verbose="true">
<fileset dir="${config.dir.src}">
<include name="**/bin/*" />
<include name="**/.lib/*" />
<include name="**/.rsl/*" />
</fileset>
</delete>
</target>
<target name="clean_setting" depends="setup" description="Clean all">
<delete includeemptydirs="true" verbose="true">
<fileset dir="${config.dir.src}">
<exclude name=".gitkeep" />
<exclude name="**/.lib/" />
<exclude name="**/.rsl/" />
<exclude name="**/.islibrary" />
<exclude name="**/.dependlib" />
<exclude name="**/.dependrsl" />
<include name="**/.*" />
<include name="**/.*/" />
</fileset>
</delete>
</target>
<target name="drop" description="Drop build config">
<delete deleteonexit="true">
<fileset dir="${basedir}">
<include name="config4*.properties" />
<include name="flex_config_*.xml" />
</fileset>
</delete>
</target>
<target name="swc" depends="setup" description="New a swc project">
<input message="Please enter some library name, delimit them with a comma:" addproperty="librarys.name" />
<foreach target="auto_gen_library" list="${librarys.name}" delimiter="," param="library.name" trim="true" parallel="true" maxthreads="4" inheritall="true" />
</target>
<target name="swf" depends="setup" description="New a swf project">
<input message="Please enter some project name, delimit them with a comma:" addproperty="projects.name" />
<foreach target="auto_gen_project" list="${projects.name}" delimiter="," param="project.name" trim="true" parallel="true" maxthreads="4" inheritall="true" />
</target>
<target name="setting" depends="setup, clean_setting" description="Gen all setting">
<foreach target="auto_gen_setting" param="project.dir" parallel="true" maxthreads="4" inheritall="true">
<path>
<dirset dir="${config.dir.src}">
<depth max="0" min="0" />
</dirset>
</path>
</foreach>
</target>
</project>