12e69de000
Semantics of the original jar and build command is not changed, it can be used as before. the ant-lib will probrably stay here and will be removed from OsmAnd project. git-svn-id: https://osmand.googlecode.com/svn/trunk@836 e29c36b1-1cfa-d876-8d93-3434fc2bb7b8
123 lines
3.5 KiB
XML
123 lines
3.5 KiB
XML
<!-- build JAR libraty -->
|
|
<project name="DataExtractionOSM" default="build" basedir=".">
|
|
|
|
<property name="file.to.upload" value="OsmAndMapCreator-nightbuild.zip"/>
|
|
<property name="src.dir" value="src"/>
|
|
<property name="src.absolute.dir" location="${src.dir}" />
|
|
<property name="bin.dir" value="bin"/>
|
|
<property name="bin.absolute.dir" location="${bin.dir}" />
|
|
<property name="lib.dir" value="lib"/>
|
|
<property name="lib.absolute.dir" location="${lib.dir}" />
|
|
|
|
<path id="ant.lib.path">
|
|
<fileset dir="ant-lib" includes="*.jar" />
|
|
</path>
|
|
|
|
<path id="build.path">
|
|
<fileset dir="${lib.absolute.dir}">
|
|
<include name="*.jar"/>
|
|
</fileset>
|
|
</path>
|
|
|
|
<property file="local.properties" />
|
|
|
|
<target name="-dirs">
|
|
<mkdir dir="${bin.absolute.dir}"/>
|
|
</target>
|
|
|
|
<target name="clean">
|
|
<delete dir="${bin.absolute.dir}"/>
|
|
</target>
|
|
|
|
<target name="compile" depends="-dirs">
|
|
<javac srcdir="${src.absolute.dir}"
|
|
destdir="${bin.absolute.dir}"
|
|
classpathref="build.path"
|
|
debug="on"
|
|
source="1.6"
|
|
/>
|
|
</target>
|
|
|
|
<target name="jar" depends="-dirs">
|
|
<manifestclasspath property="lib.list" jarfile="OsmAndMapCreator.jar">
|
|
<classpath refid="build.path"/>
|
|
</manifestclasspath>
|
|
<echo>list is ${lib.list}</echo>
|
|
|
|
<delete file="OsmAndMapCreator.jar" />
|
|
<delete file="MANIFEST.MF" />
|
|
<manifest file="MANIFEST.MF">
|
|
<attribute name="Built-By" value="${user.name}" />
|
|
<attribute name="Main-Class" value="net.osmand.swing.OsmExtractionUI" />
|
|
<attribute name="Class-Path" value="${lib.list}"/>
|
|
</manifest>
|
|
|
|
<jar destfile="OsmAndMapCreator.jar" manifest="MANIFEST.MF">
|
|
<fileset dir="${bin.absolute.dir}">
|
|
<include name="**/*" />
|
|
</fileset>
|
|
<fileset dir="${src.absolute.dir}">
|
|
<include name="**/*.java" />
|
|
</fileset>
|
|
</jar>
|
|
|
|
<delete file="MANIFEST.MF" />
|
|
</target>
|
|
|
|
<target name="build" depends="jar">
|
|
<delete dir="build"/>
|
|
<copy todir="build">
|
|
<fileset dir=".">
|
|
<include name="OsmAndMapCreator.jar"/>
|
|
<include name="lib/**"/>
|
|
<include name="logging.properties"/>
|
|
<include name="OsmAndMapCreator.bat"/>
|
|
<include name="OsmAndMapCreator.sh"/>
|
|
<include name="inspector.bat"/>
|
|
<include name="inspector.sh"/>
|
|
<exclude name="lib/h2*"/>
|
|
</fileset>
|
|
<fileset dir="src/net/osmand/osm/">
|
|
<include name="rendering_types.xml"/>
|
|
</fileset>
|
|
<fileset dir=".">
|
|
<include name="batch_indexing.bat"/>
|
|
<include name="batch_indexing.sh"/>
|
|
</fileset>
|
|
<fileset dir="src/net/osmand/data/index">
|
|
<include name="batch.xml" />
|
|
</fileset>
|
|
</copy>
|
|
<zip destfile="build.zip">
|
|
<fileset dir="build">
|
|
</fileset>
|
|
</zip>
|
|
<delete file="OsmAndMapCreator.jar" />
|
|
</target>
|
|
|
|
<typedef resource="org/tigris/subversion/svnant/svnantlib.xml" classpathref="ant.lib.path" />
|
|
|
|
<target name="update">
|
|
<svn svnkit="true">
|
|
<update dir="." revision="HEAD" />
|
|
<info target="." />
|
|
</svn>
|
|
<echo>Updated to revision: ${svn.info.rev}</echo>
|
|
</target>
|
|
|
|
<target name="nightbuild" depends="clean,update,compile,build">
|
|
<move file="build.zip" tofile="${file.to.upload}"/>
|
|
<ftp action="del" server="download.osmand.net" userid="${ftp.user}" password="${ftp.password}">
|
|
<fileset>
|
|
<include name="night-builds/${file.to.upload}" />
|
|
</fileset>
|
|
</ftp>
|
|
|
|
|
|
<ftp server="download.osmand.net" remotedir="night-builds" userid="${ftp.user}" password="${ftp.password}" depends="yes">
|
|
<fileset dir=".">
|
|
<include name="${file.to.upload}" />
|
|
</fileset>
|
|
</ftp>
|
|
</target>
|
|
</project>
|