Skip to content

Commit

Permalink
Added ant build files.
Browse files Browse the repository at this point in the history
  • Loading branch information
djcopley committed Dec 18, 2018
1 parent b02bae9 commit 57d83c5
Show file tree
Hide file tree
Showing 2 changed files with 306 additions and 0 deletions.
4 changes: 4 additions & 0 deletions argparse.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
path.variable.kotlin_bundled=/Users/djcopley/Library/Application Support/JetBrains/Toolbox/apps/IDEA-U/ch-0/183.4588.61/IntelliJ IDEA.app/Contents/plugins/Kotlin/kotlinc
path.variable.maven_repository=/Users/djcopley/.m2/repository
jdk.home.10=/Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Home
javac2.instrumentation.includeJavaRuntime=false
302 changes: 302 additions & 0 deletions argparse.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,302 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="argparse" default="all">


<property file="argparse.properties"/>
<!-- Uncomment the following property if no tests compilation is needed -->
<!--
<property name="skip.tests" value="true"/>
-->

<!-- Compiler options -->

<property name="compiler.debug" value="on"/>
<property name="compiler.generate.no.warnings" value="off"/>
<property name="compiler.args" value=""/>
<property name="compiler.max.memory" value="700m"/>
<patternset id="ignored.files">
<exclude name="**/*.hprof/**"/>
<exclude name="**/*.pyc/**"/>
<exclude name="**/*.pyo/**"/>
<exclude name="**/*.rbc/**"/>
<exclude name="**/*.yarb/**"/>
<exclude name="**/*~/**"/>
<exclude name="**/.DS_Store/**"/>
<exclude name="**/.git/**"/>
<exclude name="**/.hg/**"/>
<exclude name="**/.svn/**"/>
<exclude name="**/CVS/**"/>
<exclude name="**/__pycache__/**"/>
<exclude name="**/_svn/**"/>
<exclude name="**/vssver.scc/**"/>
<exclude name="**/vssver2.scc/**"/>
</patternset>
<patternset id="library.patterns">
<include name="*.egg"/>
<include name="*.jar"/>
<include name="*.ear"/>
<include name="*.klib"/>
<include name="*.swc"/>
<include name="*.war"/>
<include name="*.zip"/>
<include name="*.ane"/>
</patternset>
<patternset id="compiler.resources">
<exclude name="**/?*.java"/>
<exclude name="**/?*.form"/>
<exclude name="**/?*.class"/>
<exclude name="**/?*.groovy"/>
<exclude name="**/?*.scala"/>
<exclude name="**/?*.flex"/>
<exclude name="**/?*.kt"/>
<exclude name="**/?*.clj"/>
<exclude name="**/?*.aj"/>
</patternset>

<!-- JDK definitions -->

<property name="jdk.bin.10" value="${jdk.home.10}/bin"/>
<path id="jdk.classpath.10">
<fileset dir="${jdk.home.10}">
<include name="../Home!/java.activation"/>
<include name="../Home!/java.base"/>
<include name="../Home!/java.compiler"/>
<include name="../Home!/java.corba"/>
<include name="../Home!/java.datatransfer"/>
<include name="../Home!/java.desktop"/>
<include name="../Home!/java.instrument"/>
<include name="../Home!/java.jnlp"/>
<include name="../Home!/java.logging"/>
<include name="../Home!/java.management"/>
<include name="../Home!/java.management.rmi"/>
<include name="../Home!/java.naming"/>
<include name="../Home!/java.prefs"/>
<include name="../Home!/java.rmi"/>
<include name="../Home!/java.scripting"/>
<include name="../Home!/java.se"/>
<include name="../Home!/java.se.ee"/>
<include name="../Home!/java.security.jgss"/>
<include name="../Home!/java.security.sasl"/>
<include name="../Home!/java.smartcardio"/>
<include name="../Home!/java.sql"/>
<include name="../Home!/java.sql.rowset"/>
<include name="../Home!/java.transaction"/>
<include name="../Home!/java.xml"/>
<include name="../Home!/java.xml.bind"/>
<include name="../Home!/java.xml.crypto"/>
<include name="../Home!/java.xml.ws"/>
<include name="../Home!/java.xml.ws.annotation"/>
<include name="../Home!/javafx.base"/>
<include name="../Home!/javafx.controls"/>
<include name="../Home!/javafx.deploy"/>
<include name="../Home!/javafx.fxml"/>
<include name="../Home!/javafx.graphics"/>
<include name="../Home!/javafx.media"/>
<include name="../Home!/javafx.swing"/>
<include name="../Home!/javafx.web"/>
<include name="../Home!/jdk.accessibility"/>
<include name="../Home!/jdk.aot"/>
<include name="../Home!/jdk.attach"/>
<include name="../Home!/jdk.charsets"/>
<include name="../Home!/jdk.compiler"/>
<include name="../Home!/jdk.crypto.cryptoki"/>
<include name="../Home!/jdk.crypto.ec"/>
<include name="../Home!/jdk.deploy"/>
<include name="../Home!/jdk.deploy.controlpanel"/>
<include name="../Home!/jdk.dynalink"/>
<include name="../Home!/jdk.editpad"/>
<include name="../Home!/jdk.hotspot.agent"/>
<include name="../Home!/jdk.httpserver"/>
<include name="../Home!/jdk.incubator.httpclient"/>
<include name="../Home!/jdk.internal.ed"/>
<include name="../Home!/jdk.internal.jvmstat"/>
<include name="../Home!/jdk.internal.le"/>
<include name="../Home!/jdk.internal.opt"/>
<include name="../Home!/jdk.internal.vm.ci"/>
<include name="../Home!/jdk.internal.vm.compiler"/>
<include name="../Home!/jdk.internal.vm.compiler.management"/>
<include name="../Home!/jdk.jartool"/>
<include name="../Home!/jdk.javadoc"/>
<include name="../Home!/jdk.javaws"/>
<include name="../Home!/jdk.jcmd"/>
<include name="../Home!/jdk.jconsole"/>
<include name="../Home!/jdk.jdeps"/>
<include name="../Home!/jdk.jdi"/>
<include name="../Home!/jdk.jdwp.agent"/>
<include name="../Home!/jdk.jfr"/>
<include name="../Home!/jdk.jlink"/>
<include name="../Home!/jdk.jshell"/>
<include name="../Home!/jdk.jsobject"/>
<include name="../Home!/jdk.jstatd"/>
<include name="../Home!/jdk.localedata"/>
<include name="../Home!/jdk.management"/>
<include name="../Home!/jdk.management.agent"/>
<include name="../Home!/jdk.management.cmm"/>
<include name="../Home!/jdk.management.jfr"/>
<include name="../Home!/jdk.management.resource"/>
<include name="../Home!/jdk.naming.dns"/>
<include name="../Home!/jdk.naming.rmi"/>
<include name="../Home!/jdk.net"/>
<include name="../Home!/jdk.pack"/>
<include name="../Home!/jdk.packager"/>
<include name="../Home!/jdk.packager.services"/>
<include name="../Home!/jdk.plugin"/>
<include name="../Home!/jdk.plugin.server"/>
<include name="../Home!/jdk.rmic"/>
<include name="../Home!/jdk.scripting.nashorn"/>
<include name="../Home!/jdk.scripting.nashorn.shell"/>
<include name="../Home!/jdk.sctp"/>
<include name="../Home!/jdk.security.auth"/>
<include name="../Home!/jdk.security.jgss"/>
<include name="../Home!/jdk.snmp"/>
<include name="../Home!/jdk.unsupported"/>
<include name="../Home!/jdk.xml.bind"/>
<include name="../Home!/jdk.xml.dom"/>
<include name="../Home!/jdk.xml.ws"/>
<include name="../Home!/jdk.zipfs"/>
<include name="../Home!/oracle.desktop"/>
<include name="../Home!/oracle.net"/>
</fileset>
</path>

<property name="project.jdk.home" value="${jdk.home.10}"/>
<property name="project.jdk.bin" value="${jdk.bin.10}"/>
<property name="project.jdk.classpath" value="jdk.classpath.10"/>


<!-- Project Libraries -->

<path id="library.maven:_arquillian_junit:release.classpath">
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/config/arquillian-config-api/1.4.1.Final/arquillian-config-api-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/config/arquillian-config-impl-base/1.4.1.Final/arquillian-config-impl-base-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/config/arquillian-config-spi/1.4.1.Final/arquillian-config-spi-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/container/arquillian-container-impl-base/1.4.1.Final/arquillian-container-impl-base-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/container/arquillian-container-spi/1.4.1.Final/arquillian-container-spi-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/container/arquillian-container-test-api/1.4.1.Final/arquillian-container-test-api-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/container/arquillian-container-test-impl-base/1.4.1.Final/arquillian-container-test-impl-base-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/container/arquillian-container-test-spi/1.4.1.Final/arquillian-container-test-spi-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/core/arquillian-core-api/1.4.1.Final/arquillian-core-api-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/core/arquillian-core-impl-base/1.4.1.Final/arquillian-core-impl-base-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/core/arquillian-core-spi/1.4.1.Final/arquillian-core-spi-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/junit/arquillian-junit-container/1.4.1.Final/arquillian-junit-container-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/junit/arquillian-junit-core/1.4.1.Final/arquillian-junit-core-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/test/arquillian-test-api/1.4.1.Final/arquillian-test-api-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/test/arquillian-test-impl-base/1.4.1.Final/arquillian-test-impl-base-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/arquillian/test/arquillian-test-spi/1.4.1.Final/arquillian-test-spi-1.4.1.Final.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/shrinkwrap/descriptors/shrinkwrap-descriptors-api-base/2.0.0/shrinkwrap-descriptors-api-base-2.0.0.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/shrinkwrap/descriptors/shrinkwrap-descriptors-spi/2.0.0/shrinkwrap-descriptors-spi-2.0.0.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/shrinkwrap/shrinkwrap-api/1.2.6/shrinkwrap-api-1.2.6.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/shrinkwrap/shrinkwrap-impl-base/1.2.6/shrinkwrap-impl-base-1.2.6.jar"/>
<pathelement location="${path.variable.maven_repository}/org/jboss/shrinkwrap/shrinkwrap-spi/1.2.6/shrinkwrap-spi-1.2.6.jar"/>
</path>
<!-- Register Custom Compiler Taskdefs -->
<property name="javac2.home" value="${idea.home}/lib"/>
<path id="javac2.classpath">
<fileset dir="${javac2.home}">
<include name="javac2.jar"/>
<include name="jdom.jar"/>
<include name="asm-all*.jar"/>
<include name="forms-*.jar"/>
</fileset>
</path>
<target name="register.custom.compilers">
<taskdef name="javac2" classname="com.intellij.ant.Javac2" classpathref="javac2.classpath"/>
<taskdef name="instrumentIdeaExtensions" classname="com.intellij.ant.InstrumentIdeaExtensions" classpathref="javac2.classpath"/>
</target>

<!-- Modules -->


<!-- Module argparse -->

<dirname property="module.argparse.basedir" file="${ant.file}"/>


<property name="module.jdk.home.argparse" value="${project.jdk.home}"/>
<property name="module.jdk.bin.argparse" value="${project.jdk.bin}"/>
<property name="module.jdk.classpath.argparse" value="${project.jdk.classpath}"/>

<property name="compiler.args.argparse" value="-encoding UTF-8 -source 10 -target 10 ${compiler.args}"/>

<property name="argparse.output.dir" value="${module.argparse.basedir}/out/production/argparse"/>
<property name="argparse.testoutput.dir" value="${module.argparse.basedir}/out/test/argparse"/>

<path id="argparse.module.bootclasspath">
<!-- Paths to be included in compilation bootclasspath -->
</path>

<path id="argparse.module.production.classpath">
<path refid="${module.jdk.classpath.argparse}"/>
<path refid="library.maven:_arquillian_junit:release.classpath"/>
</path>

<path id="argparse.runtime.production.module.classpath">
<pathelement location="${argparse.output.dir}"/>
<path refid="library.maven:_arquillian_junit:release.classpath"/>
</path>

<path id="argparse.module.classpath">
<path refid="${module.jdk.classpath.argparse}"/>
<pathelement location="${argparse.output.dir}"/>
<path refid="library.maven:_arquillian_junit:release.classpath"/>
</path>

<path id="argparse.runtime.module.classpath">
<pathelement location="${argparse.testoutput.dir}"/>
<pathelement location="${argparse.output.dir}"/>
<path refid="library.maven:_arquillian_junit:release.classpath"/>
</path>


<patternset id="excluded.from.module.argparse">
<patternset refid="ignored.files"/>
</patternset>

<patternset id="excluded.from.compilation.argparse">
<patternset refid="excluded.from.module.argparse"/>
</patternset>

<path id="argparse.module.sourcepath">
<dirset dir="${module.argparse.basedir}">
<include name="src"/>
</dirset>
</path>


<target name="compile.module.argparse" depends="compile.module.argparse.production,compile.module.argparse.tests" description="Compile module argparse"/>

<target name="compile.module.argparse.production" depends="register.custom.compilers" description="Compile module argparse; production classes">
<mkdir dir="${argparse.output.dir}"/>
<javac2 destdir="${argparse.output.dir}" debug="${compiler.debug}" nowarn="${compiler.generate.no.warnings}" memorymaximumsize="${compiler.max.memory}" fork="true" executable="${module.jdk.bin.argparse}/javac">
<compilerarg line="${compiler.args.argparse}"/>
<bootclasspath refid="argparse.module.bootclasspath"/>
<classpath refid="argparse.module.production.classpath"/>
<src refid="argparse.module.sourcepath"/>
<patternset refid="excluded.from.compilation.argparse"/>
</javac2>

<copy todir="${argparse.output.dir}">
<fileset dir="${module.argparse.basedir}/src">
<patternset refid="compiler.resources"/>
<type type="file"/>
</fileset>
</copy>
</target>

<target name="compile.module.argparse.tests" depends="register.custom.compilers,compile.module.argparse.production" description="compile module argparse; test classes" unless="skip.tests"/>

<target name="clean.module.argparse" description="cleanup module">
<delete dir="${argparse.output.dir}"/>
<delete dir="${argparse.testoutput.dir}"/>
</target>

<target name="init" description="Build initialization">
<!-- Perform any build initialization in this target -->
</target>

<target name="clean" depends="clean.module.argparse" description="cleanup all"/>

<target name="build.modules" depends="init, clean, compile.module.argparse" description="build all modules"/>

<target name="all" depends="build.modules" description="build all"/>
</project>

0 comments on commit 57d83c5

Please sign in to comment.