-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.xml
40 lines (34 loc) · 1.54 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
<project default="build" basedir=".">
<description>Build file for flashblocks library.</description>
<!-- build properties -->
<property name="src.dir" value="${basedir}/src"/>
<property name="bin.dir" value="${basedir}/bin"/>
<property name="build.dir" value="${basedir}/build"/>
<!-- env properties -->
<property environment="env"/>
<property name="FLEX_HOME" value="${env.FLEX_HOME}"/>
<macrodef name="build-swf-macro">
<attribute name="app" />
<attribute name="swf" default="@{app}" />
<attribute name="swfFile" default="${bin.dir}/@{swf}.swf" />
<attribute name="mxmlFile" />
<sequential>
<!-- java task method of calling mxmlc.jar -->
<java jar="${FLEX_HOME}/lib/mxmlc.jar" dir="." fork="true" failonerror="true">
<jvmarg value="-Xmx512m" />
<arg value="-local-fonts-snapshot=${FLEX_HOME}/frameworks/localFonts.ser"/>
<arg value="-load-config=${FLEX_HOME}/frameworks/flex-config.xml"/>
<arg value="-load-config+=${build.dir}/flex-config.xml"/>
<arg value="-output=@{swfFile}" />
<arg value="@{mxmlFile}" />
</java>
</sequential>
</macrodef>
<target name="build" depends="clean, build-swf"/>
<target name="clean">
<delete file="bin/webclient.swf"/>
</target>
<target name="build-swf">
<build-swf-macro app="webclient" mxmlFile="${src.dir}/battlecode/client/viewer/MatchViewer.mxml"/>
</target>
</project>