Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
tree: 7706921f46
Fetching contributors…

Cannot retrieve contributors at this time

259 lines (201 sloc) 10.366 kb
<?xml version="1.0"?>
<project name="log5f-core" default="build" basedir=".">
<!--=====================================================================-->
<!-- Libraries -->
<!--=====================================================================-->
<!--===============================-->
<!-- FlexAntTasks (Flex Applications Unit Testing) -->
<!--===============================-->
<taskdef resource="com/adobe/ac/ant/tasks/tasks.properties" classpath="ant-libs/FlexAntTasks.jar" />
<!--===============================-->
<!-- FlexTasks (Compiling Flex Applications) -->
<!--===============================-->
<taskdef resource="flexTasks.tasks" classpath="ant-libs/flexTasks.jar" />
<!--===============================-->
<!-- SVNAnt (http://subclipse.tigris.org/svnant/svn.html) -->
<!--===============================-->
<path id="path.svnant">
<fileset dir="ant-libs">
<include name="**/*.jar" />
</fileset>
</path>
<typedef resource="org/tigris/subversion/svnant/svnantlib.xml" classpathref="path.svnant" />
<!--=====================================================================-->
<!-- Propertiers -->
<!--=====================================================================-->
<property name="project" value="log5f" />
<property name="dependencies" value="" />
<property name="artifact.tmpl.file" value="" />
<!--===============================-->
<!-- Build -->
<!--===============================-->
<property file="build.properties" />
<!--===============================-->
<!-- Flex -->
<!--===============================-->
<property name="FLEX_HOME" location="${flex.sdk}" />
<property name="APP_ROOT" location="${basedir}" />
<property name="LOCALE" value="en_US" />
<!--===============================-->
<!-- JARs -->
<!--===============================-->
<property name="asdoc.jar" location="${flex.sdk}/lib/asdoc.jar" />
<property name="digest.jar" location="${flex.sdk}/lib/digest.jar" />
<property name="optimizer.jar" location="${flex.sdk}/lib/optimizer.jar" />
<!--===============================-->
<!-- Application -->
<!--===============================-->
<property name="lib.debug" value="false" />
<property name="lib.dir" location="${basedir}" />
<property name="lib.src" location="${lib.dir}/src/" />
<property name="lib.bin" location="${lib.dir}/bin/" />
<property name="lib.bin.rsl" location="${lib.dir}/bin/rsl/" />
<property name="lib.libs" location="${lib.dir}/libs/" />
<property name="lib.temp" location="${basedir}/temp/" />
<property name="lib.assets" location="${lib.src}/assets/" />
<property name="lib.input.mxml" location="${lib.src}/index.mxml" />
<property name="lib.output.swf" location="${lib.bin}/index.swf" />
<!--===============================-->
<!-- Metadata -->
<!--===============================-->
<property name="meta.creator" value="max.rozdobudko@gmail.com" />
<property name="meta.contributor" value="log5f.org" />
<property name="meta.language" value="EN" />
<property name="meta.description" value="Log5F Flash Logging Tool" />
<!--===============================-->
<!-- ASDoc -->
<!--===============================-->
<property name="asdoc.src" location="${lib.src}/" />
<property name="asdoc.output" location="${lib.dir}/asdocs" />
<property name="asdoc.main.title" value="${meta.contributor}" />
<property name="asdoc.window.title" value="${meta.description}" />
<property name="asdoc.window.footer" value="http://log5f.org" />
<!--===============================-->
<!-- SVN -->
<!--===============================-->
<svnSetting svnkit="true" javahl="false" username="" password="" id="svn.settings" />
<!--===============================-->
<!-- Version -->
<!--===============================-->
<property name="version.file" location="../version.number" />
<property file="${version.file}" />
<!--===============================-->
<!-- environment -->
<!--===============================-->
<property environment="env" />
<!--=====================================================================-->
<!-- Conditions -->
<!--=====================================================================-->
<!-- The build number 0000 means, that library was build as dev version -->
<property name="env.BUILD_NUMBER" value="0000" />
<!--=====================================================================-->
<!-- Targets -->
<!--=====================================================================-->
<!--===============================-->
<!-- Build -->
<!--===============================-->
<target name="build" depends="build.rsl, build.api" description="Build Log5F">
<echo>${env.BUILD_NUMBER}</echo>
</target>
<target name="build.compile" description="Compile Library">
<replaceregexp file="${lib.src}/org/log5f/Log5F.as" match='public static const VERSION:String = "*.*.*"' replace='public static const VERSION:String = "${version.major}.${version.minor}.${env.BUILD_NUMBER}"' byline="true" />
<compc output="${lib.bin}/log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swc" locale="${LOCALE}" debug="${lib.debug}">
<source-path path-element="${lib.src}" />
<source-path path-element="${basedir}/locale/${LOCALE}" />
<include-file name="design.xml" path="${lib.src}/design.xml" />
<include-file name="manifest.xml" path="${lib.src}/manifest.xml" />
<namespace uri="http://log5f.org" manifest="${lib.src}/manifest.xml" />
<include-namespaces uri="http://log5f.org" />
<include-sources dir="${lib.src}" includes="*" append="true">
<exclude name="*.xml" />
<exclude name="*.properties" />
<exclude name="*.xsd" />
</include-sources>
<strict>true</strict>
<optimize>true</optimize>
<warnings>true</warnings>
<compute-digest>true</compute-digest>
</compc>
<replaceregexp file="${lib.src}/org/log5f/Log5F.as" match='public static const VERSION:String = "*.*.*"' replace='public static const VERSION:String = "${version.major}.${version.minor}.0000"' byline="true" />
<echo>${env.BUILD_NUMBER}</echo>
</target>
<!--===============================-->
<!-- RSL -->
<!--===============================-->
<target name="build.rsl" depends="build.compile" description="Make RSL">
<sequential>
<unzip src="${lib.bin}/log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swc" dest="${lib.bin.rsl}">
<patternset>
<include name="library.swf" />
</patternset>
</unzip>
<java jar="${optimizer.jar}" fork="true" failonerror="true">
<jvmarg line="-ea -DAS3 -DAVMPLUS -Xms32m -Xmx384m -Dsun.io.useCanonCaches=false" />
<arg line="-input ${lib.bin.rsl}/library.swf" />
<arg line="-output ${lib.bin.rsl}/log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swf" />
<arg line="-keep-as3-metadata='Bindable,Managed,ChangeEvent,NonCommittingChangeEvent,Transient'" />
</java>
<delete file="${lib.bin.rsl}/library.swf" />
<java jar="${digest.jar}" fork="true" failonerror="true">
<jvmarg line="-ea -DAS3 -DAVMPLUS -Xms32m -Xmx384m -Dsun.io.useCanonCaches=false" />
<arg line="--digest.rsl-file ${lib.bin.rsl}/log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swf" />
<arg line="--digest.swc-path ${lib.bin}/log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swc" />
</java>
</sequential>
</target>
<!--===============================-->
<!-- ASDoc -->
<!--===============================-->
<target name="build.api" description="Build asdocs">
<asdoc output="${asdoc.output}" lenient="true" failonerror="true">
<doc-sources path-element="${asdoc.src}" />
<namespace uri="http://log5f.org" manifest="${lib.src}/manifest.xml" />
</asdoc>
</target>
<!--===============================-->
<!-- HTML -->
<!--===============================-->
<target name="build.hudson.artifacts">
<copy file="${basedir}/build/artifacts.html" todir="${lib.bin}" overwrite="true" />
<move file="${lib.bin}/artifacts.html" tofile="${lib.bin}/index.html" overwrite="true" />
<tstamp>
<format property="touch.time" pattern="MM/dd/yyyy hh:mm:ss" offset="0" unit="hour" />
</tstamp>
<replaceregexp file="${lib.bin}/index.html" match='%ARTIFACT_ID%' replace='Log5F' byline="true" />
<replaceregexp file="${lib.bin}/index.html" match='%ARTIFACT_DESCRIPTION%' replace='Core Library' byline="true" />
<replaceregexp file="${lib.bin}/index.html" match='%BUILD_NUMBER%' replace='${version.major}.${version.minor}.${env.BUILD_NUMBER}' byline="true" />
<replaceregexp file="${lib.bin}/index.html" match='%BUILD_DATE%' replace='${touch.time}' byline="true" />
<replaceregexp file="${lib.bin}/index.html" match='%DOWNLOAD%' replace='log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swc' byline="true" />
</target>
<!--===============================-->
<!-- Artifacts -->
<!--===============================-->
<target name="artifact.create.table">
<tstamp>
<format property="touch.time" pattern="MM/dd/yyyy hh:mm:ss" offset="0" unit="hour" />
</tstamp>
<copy file="${artifact.tmpl.file}" toFile="${lib.temp}/artifact.tmpl">
<filterchain>
<replacetokens>
<token key="ARTIFACT_ID" value="Log5F"/>
<token key="ARTIFACT_DESCRIPTION" value="Core Library"/>
<token key="BUILD_NUMBER" value="${version.major}.${version.minor}.${env.BUILD_NUMBER}"/>
<token key="BUILD_DATE" value="${touch.time}"/>
<token key="DOWNLOAD" value="log5f-${version.major}.${version.minor}.${env.BUILD_NUMBER}.swc"/>
</replacetokens>
</filterchain>
</copy>
</target>
<!--===============================-->
<!-- Project -->
<!--===============================-->
<target name="project.export" description="Archive Project">
<svn refid="svn.settings">
<export srcPath="${basedir}" destPath="${basedir}/temp" force="true" />
</svn>
<zip destfile="${basedir}/Log5F-${version.major}.${version.minor}.zip" basedir="${basedir}/temp">
<exclude name="${basedir}/**.zip" />
</zip>
<delete dir="${basedir}/temp" />
</target>
</project>
Jump to Line
Something went wrong with that request. Please try again.