Files
2018-12-03 17:31:53 +08:00

231 lines
7.9 KiB
XML

<?xml version="1.0"?>
<project name="flex ant build" default="build-release" basedir=".">
<property environment="env" />
<property file="build.properties" />
<taskdef name="mxmlc" classname="flex.ant.MxmlcTask" classpath="${FLEX_HOME}/ant/lib/flexTasks.jar" />
<taskdef name="compc" classname="flex.ant.CompcTask" classpath="${FLEX_HOME}/ant/lib/flexTasks.jar" />
<target name="build-release">
<antcall target="clean" />
<antcall target="init" />
<antcall target="compileBase" />
<antcall target="compileVideo" />
<antcall target="compileEffect" />
<antcall target="compilePlug" />
<antcall target="compileMain" />
<antcall target="createRSL" />
<antcall target="createPluginRSL" />
<antcall target="compileCore" />
<antcall target="compileTemplete" />
</target>
<target name="clean">
<delete dir="${PK_TEMPLETE_OUTPUT_REALEASE}"/>
</target>
<target name="init">
<mkdir dir="${PK_TEMPLETE_OUTPUT_REALEASE}"/>
<copy todir="${PK_TEMPLETE_OUTPUT_REALEASE}">
<fileset dir="${PK_TEMPLETE_HTML}" />
</copy>
</target>
<target name="compileBase">
<compc output="${PK_BASE}/bin/vippk-yy-base_v3_d.swc" locale="${LOCALE}" actionscript-file-encoding="UTF-8" fork="true" debug="${debug}"
optimize="true">
<source-path path-element="${PK_BASE}/src" />
<include-sources dir="${PK_BASE}/src" includes="*" excludes="*.bak"/>
<define name="VERSION::VER" value="4" />
<define name="PKCONFIG::MODE" value="0" />
<define name="PLUGIN::DEBUG" value="false" />
<library-path dir="${PK_BASE}/lib2" includes="*" append="true" />
<external-library-path dir="${FLEX_HOME}/frameworks/libs" includes="framework.swc" append="true" />
<external-library-path dir="${PK_BASE}/lib" includes="*" append="true" />
</compc>
</target>
<target name="compileVideo">
<compc output="${PK_VIDEO}/bin/vippk-yy-video_v1.swc" locale="${LOCALE}" actionscript-file-encoding="UTF-8" fork="true" debug="${debug}"
optimize="true">
<source-path path-element="${PK_VIDEO}/src" />
<include-sources dir="${PK_VIDEO}/src" includes="*" excludes="*.bak"/>
<library-path dir="${PK_VIDEO}/lib" includes="*" append="true" />
<external-library-path dir="${FLEX_HOME}/frameworks/libs" includes="framework.swc" append="true" />
<external-library-path dir="${FLEX_HOME}/frameworks/libs/mx" includes="mx.swc" append="true" />
<external-library-path dir="${PK_BASE}/bin" includes="*" append="true" />
</compc>
</target>
<target name="compileEffect">
<compc output="${PK_EFFECT}/bin/vippk-yy-effect_v3_b.swc" locale="${LOCALE}" actionscript-file-encoding="UTF-8" fork="true" debug="${debug}"
optimize="true">
<source-path path-element="${PK_EFFECT}/src" />
<include-sources dir="${PK_EFFECT}/src" includes="*" excludes="*.bak"/>
<external-library-path dir="${FLEX_HOME}/frameworks/libs" includes="framework.swc" append="true" />
<external-library-path dir="${PK_BASE}/bin" includes="*" append="true" />
<external-library-path dir="${PK_EFFECT}/lib" includes="*" append="true" />
<external-library-path dir="${PK_EFFECT}/lib2" includes="*" append="true" />
</compc>
</target>
<target name="compilePlug">
<compc output="${PK_PLUGINS}/bin/vippk-yy-plugins_v3_d.swc" locale="${LOCALE}" actionscript-file-encoding="UTF-8" debug="${debug}"
fork="true" optimize="true">
<source-path path-element="${PK_PLUGINS}/src" />
<include-sources dir="${PK_PLUGINS}/src" includes="*" excludes="*.bak"/>
<library-path dir="${PK_PLUGINS}/lib2" includes="*.swc" append="true" />
<library-path dir="${PK_BASE}/bin" includes="*" append="true" />
<library-path dir="${PK_EFFECT}/bin" includes="*" append="true" />
<library-path dir="${PK_PLUGINS}/lib" includes="*.swc" append="true" />
<external-library-path dir="${FLEX_HOME}/frameworks/libs" includes="framework.swc" append="true" />
</compc>
</target>
<target name="compileMain">
<compc output="${PK_MAIN}/bin/vippk-yy-main_v3_d.swc" locale="${LOCALE}" actionscript-file-encoding="UTF-8" fork="true" debug="${debug}"
optimize="true">
<define name="PKCONFIG::MODE" value="${PKCONFIG_MODE}" />
<define name="PLUGIN::DEBUG" value="${PLUGIN_DEBUG}" />
<define name="PUB::USE_RSL" value="${PUB_USE_RSL}" />
<source-path path-element="${PK_MAIN}/src" />
<include-sources dir="${PK_MAIN}/src" includes="*" excludes="*.bak"/>
<external-library-path dir="${FLEX_HOME}/frameworks/libs" includes="framework.swc" append="true" />
<external-library-path dir="${FLEX_HOME}/frameworks/libs/mx" includes="mx.swc" append="true" />
<external-library-path dir="${PK_BASE}/bin" includes="*" append="true" />
<external-library-path dir="${PK_VIDEO}/bin" includes="*" append="true" />
<external-library-path dir="${PK_EFFECT}/bin" includes="*" append="true" />
<external-library-path dir="${PK_PLUGINS}/bin" includes="*" append="true" />
<external-library-path dir="${PK_MAIN}/lib" includes="*" append="true" />
<external-library-path dir="${PK_MAIN}/lib2" includes="*" append="true" />
</compc>
</target>
<target name="compileCore">
<mxmlc file="${PK_TEMPLETE}/src/core2.as" output="${PK_TEMPLETE_OUTPUT_REALEASE}/core2.swf" locale="${LOCALE}" actionscript-file-encoding="UTF-8" debug="${debug}"
fork="true" optimize="true">
<static-link-runtime-shared-libraries>true</static-link-runtime-shared-libraries>
<define name="PKCONFIG::MODE" value="${PKCONFIG_MODE}" />
<define name="PLUGIN::DEBUG" value="${PLUGIN_DEBUG}" />
<define name="PUB::USE_RSL" value="${PUB_USE_RSL}" />
<library-path dir="${FLEX_HOME}/frameworks/locale/${LOCALE}" includes="*" append="true" />
</mxmlc>
</target>
<target name="compileTemplete">
<mxmlc file="${PK_TEMPLETE}/src/main.as" output="${PK_TEMPLETE_OUTPUT_REALEASE}/main.swf" locale="${LOCALE}" actionscript-file-encoding="UTF-8" debug="${debug}"
fork="true" optimize="true">
<static-link-runtime-shared-libraries>true</static-link-runtime-shared-libraries>
<define name="PKCONFIG::MODE" value="${PKCONFIG_MODE}" />
<define name="PLUGIN::DEBUG" value="${PLUGIN_DEBUG}" />
<define name="PUB::USE_RSL" value="${PUB_USE_RSL}" />
<library-path dir="${FLEX_HOME}/frameworks/locale/${LOCALE}" includes="*" append="true" />
<library-path dir="${PK_BASE}/bin" includes="*" append="true" />
<library-path dir="${PK_VIDEO}/bin" includes="*" append="true" />
<library-path dir="${PK_EFFECT}/bin" includes="*" append="true" />
<library-path dir="${PK_MAIN}/bin" includes="*" append="true" />
<library-path dir="${PK_TEMPLETE}/lib" includes="*" append="true" />
<library-path dir="${PK_TEMPLETE}/lib2" includes="*" append="true" />
<!--<external-library-path dir="${PK_PLUGINS}/bin" includes="*" append="true" />-->
</mxmlc>
</target>
<target name="createRSL">
<macrodef name="optimize-rsl">
<attribute name="rsl-dir" />
<attribute name="swc-dir" />
<attribute name="swc-name" />
<sequential>
<unzip src="@{swc-dir}/@{swc-name}.swc" dest="@{rsl-dir}">
<patternset>
<include name="library.swf" />
</patternset>
</unzip>
<move file="@{rsl-dir}/library.swf" tofile="@{rsl-dir}/@{swc-name}.swf" />
</sequential>
</macrodef>
<optimize-rsl rsl-dir="${PK_TEMPLETE_OUTPUT_REALEASE}/rsls" swc-dir="${PK_BASE}/bin" swc-name="vippk-yy-base_v3_d" />
</target>
<target name="createPluginRSL">
<macrodef name="optimize-rsl">
<attribute name="rsl-dir" />
<attribute name="swc-dir" />
<attribute name="swc-name" />
<sequential>
<unzip src="@{swc-dir}/@{swc-name}.swc" dest="@{rsl-dir}">
<patternset>
<include name="library.swf" />
</patternset>
</unzip>
<move file="@{rsl-dir}/library.swf" tofile="@{rsl-dir}/library.swf" />
</sequential>
</macrodef>
<optimize-rsl rsl-dir="${PK_TEMPLETE_OUTPUT_REALEASE}/plugins" swc-dir="${PK_PLUGINS}/bin" swc-name="vippk-yy-plugins_v3_d" />
</target>
</project>