mirror of
https://github.com/processing/processing4.git
synced 2026-02-11 17:40:48 +01:00
74 lines
2.1 KiB
XML
74 lines
2.1 KiB
XML
<project name="downloader" default="dist">
|
|
|
|
<path id="classpath.base">
|
|
<!-- kinda gross, but if not using the JDT, this just ignored anyway -->
|
|
<pathelement location="${jdt.jar};" />
|
|
<pathelement location="${java.mode}/jdtCompilerAdapter.jar" />
|
|
</path>
|
|
|
|
<path id="classpath.test">
|
|
<pathelement location="../../core/library-test/junit-4.8.1.jar" />
|
|
<pathelement location = "bin-test" />
|
|
<path refid="classpath.base" />
|
|
</path>
|
|
|
|
<macrodef name="compilecommon">
|
|
<attribute name="destdir"/>
|
|
<attribute name="srcdir"/>
|
|
<attribute name="classpath"/>
|
|
<sequential>
|
|
<mkdir dir="@{destdir}" />
|
|
|
|
<!-- Where can I expect to find Java Mode JARs? -->
|
|
<property name="java.mode" value="../../java/mode/" />
|
|
|
|
<javac source="11"
|
|
target="11"
|
|
srcdir="@{srcdir}"
|
|
destdir="@{destdir}"
|
|
debug="true"
|
|
includeantruntime="true"
|
|
nowarn="true">
|
|
<classpath refid="@{classpath}"/>
|
|
</javac>
|
|
</sequential>
|
|
</macrodef>
|
|
|
|
<target name="test-compile">
|
|
<!-- <compilecommon srcdir="src; test" destdir="bin-test" classpath="classpath.test" /> -->
|
|
</target>
|
|
|
|
<target name="test" depends="test-compile">
|
|
<junit haltonfailure="true">
|
|
<classpath refid="classpath.test" />
|
|
<formatter type="brief" usefile="false" />
|
|
<!-- <test name="AdoptOpenJdkDownloadUrlGeneratorTest" /> -->
|
|
</junit>
|
|
</target>
|
|
|
|
<target name="compile">
|
|
<compilecommon srcdir="src" destdir="bin" classpath="classpath.base" />
|
|
</target>
|
|
|
|
<target name="dist-no-test" depends="compile">
|
|
<jar basedir="bin" destfile="downloader.jar" />
|
|
</target>
|
|
|
|
<target name="dist" depends="test, dist-no-test" />
|
|
|
|
<target name="demo" depends="dist">
|
|
<taskdef name="downloader"
|
|
classname="Downloader"
|
|
classpath="downloader.jar" />
|
|
<downloader version="8" update="31" build="13"
|
|
jdk="true" flavor="macosx-x64.dmg" />
|
|
</target>
|
|
|
|
<target name="clean">
|
|
<delete dir="bin" />
|
|
<delete dir="bin-test" />
|
|
<delete file="downloader.jar" />
|
|
</target>
|
|
|
|
</project>
|