- </proguard>
- <delete file="in.jar" />
- </target>
-
- <target name="castorbinding" depends="init" description="Generate Java bindings to supported Jalview XML models.">
- <taskdef name="castor-srcgen" classname="org.castor.anttask.CastorCodeGenTask" classpathref="build.classpath" />
- <delete>
- <fileset dir="${sourceDir}/jalview/schemabinding/version2">
- <include name="*.java" />
- <include name="descriptors/*.java" />
- </fileset>
- </delete>
- <castor-srcgen file="${schemaDir}/vamsas.xsd" todir="${sourceDir}" package="jalview.schemabinding.version2" warnings="false" nodesc="false" verbose="true" properties="${schemaDir}/jalview.properties" />
- <castor-srcgen file="${schemaDir}/JalviewUserColours.xsd" todir="${sourceDir}" package="jalview.schemabinding.version2" warnings="false" nodesc="false" verbose="true" properties="${schemaDir}/jalview.properties" />
- <castor-srcgen file="${schemaDir}/JalviewWsParamSet.xsd" todir="${sourceDir}" package="jalview.schemabinding.version2" warnings="false" nodesc="false" verbose="true" properties="${schemaDir}/jalview.properties" />
- <castor-srcgen file="${schemaDir}/jalview.xsd" todir="${sourceDir}" package="jalview.schemabinding.version2" warnings="false" nodesc="false" verbose="true" properties="${schemaDir}/jalview.properties" />
- <!--
- now build the jalview.binding package with the old schema set
- -->
- <delete>
- <fileset dir="${sourceDir}/jalview/binding/">
- <include name="**" />
- </fileset>
- </delete>
- <castor-srcgen file="${schemaDir}/vamsasJvV1.xsd" todir="${sourceDir}" package="jalview.binding" warnings="false" nodesc="true" verbose="true" properties="${schemaDir}/jalview.nodesc.properties" />
- <castor-srcgen file="${schemaDir}/JalviewUserColours.xsd" todir="${sourceDir}" package="jalview.binding" warnings="false" nodesc="true" verbose="true" properties="${schemaDir}/jalview.nodesc.properties" />
- <castor-srcgen file="${schemaDir}/jalviewJvV1.xsd" todir="${sourceDir}" package="jalview.binding" warnings="false" nodesc="true" verbose="true" properties="${schemaDir}/jalview.nodesc.properties" />
- </target>
- <target name="sourcedist" description="create jalview source distribution" depends="init">
- <delete file="${source.dist.name}" />
- <tar destfile="${source.dist.name}" compression="gzip">
- <tarfileset dir="./" prefix="jalview" preserveLeadingSlashes="true">
- <include name="LICENSE" />
- <include name="README" />
- <include name="build.xml" />
- <include name="jalview-jalopy.xml" />
- <include name="JalviewApplet.jpx" />
- <include name="JalviewX.jpx" />
- <include name="nbbuild.xml"/>
- <include name="nbproject/genfiles.properties"/>
- <include name="nbproject/project.properties"/>
- <include name="nbproject/project.xml"/>
- <include name="${sourceDir}/*.java" />
- <include name="${sourceDir}/**/*.java" />
- <include name="${sourceDir}/**/*.cdr" />
- <include name="${libDir}/**/*" />
- <include name="${resourceDir}/**/*" />
- <include name="${helpDir}/**/*" />
- <include name="appletlib/${jmolJar}" />
- <exclude name="**/*locales" />
- <exclude name="*locales/**" />
- <exclude name="utils/InstallAnywhere/**Build.iap_xml" />
- <exclude name="utils/InstallAnywhere/**Build*/**" />
- <exclude name="utils/InstallAnywhere/**Build*/**" />
- <exclude name="utils/InstallAnywhere/**locale*" />
- <exclude name="utils/InstallAnywhere/**locale*/**" />
- <include name="${schemaDir}/**/*" />
- <include name="utils/**/*" />
- <include name="${docDir}/**/*" />
- <include name="examples/**/*" />
- </tarfileset>
- </tar>
- </target>
- <target name="pubapplet" description="installs the jalviewLite applet and dependent jars into an applet examples directory built under ${outputDir}" depends="makeApplet">
- <copy todir="${packageDir}/examples">
- <fileset dir="examples">
- <include name="**/*"/>
- <include name="javascript/*"/>
- <include name="jmol/*"/>
- </fileset>
- <fileset dir=".">
- <include name="jalviewApplet.jar"/>
- </fileset>
- <fileset dir="appletlib">
- <include name="**/*"/>
- </fileset>
- </copy>
- <jar update="true" index="true" jarfile="${packageDir}/examples/${jalviewLiteJar}"/>
- <jar update="true" index="true" jarfile="${packageDir}/examples/$(jmolJar}"/>
- <signjar storepass="${jalview.keystore.pass}" keypass="${jalview.key.pass}" keystore="${jalview.keystore}" alias="${jalview.key}" lazy="false" verbose="false">
-
- <fileset dir="${packageDir}/examples">
- <include name="*.jar" />
- </fileset>
- </signjar>
- </target>
- <target name="sourcedoc" description="Create jalview source documentation pages" depends="init">
- <javadoc destdir="${javadocDir}">
- <packageset dir="${sourceDir}" includes="jalview/*,MCView/*">
- </packageset>
- </javadoc>
- </target>
-
+ </proguard>
+ <delete file="in.jar" />
+</target>
+
+<target name="jaxb-bindings" depends="init" description="Generates JAXB bindings for supported Jalview XML models (needs xjc on the path)">
+ <delete>
+ <fileset dir="${sourceDir}/jalview/xml/binding/jalview">
+ <include name="*.java" />
+ </fileset>
+ </delete>
+ <exec executable="xjc">
+ <arg value="${schemaDir}/jalview.xsd"/>
+ <arg value="-d"/>
+ <arg value="${sourceDir}"/>
+ <arg value="-p"/>
+ <arg value="jalview.xml.binding.jalview"/>
+ </exec>
+ <delete>
+ <fileset dir="${sourceDir}/jalview/xml/binding/embl">
+ <include name="*.java" />
+ </fileset>
+ </delete>
+
+ <exec executable="xjc">
+ <arg value="${schemaDir}/embl.xsd"/>
+ <arg value="-d"/>
+ <arg value="${sourceDir}"/>
+ <arg value="-b"/>
+ <arg value="${schemaDir}/embl_bindings.xml"/>
+ <arg value="-p"/>
+ <arg value="jalview.xml.binding.embl"/>
+ </exec>
+
+ <delete>
+ <fileset dir="${sourceDir}/jalview/xml/binding/uniprot">
+ <include name="*.java" />
+ </fileset>
+ </delete>
+
+ <exec executable="xjc">
+ <arg value="${schemaDir}/uniprot.xsd"/>
+ <arg value="-d"/>
+ <arg value="${sourceDir}"/>
+ <arg value="-p"/>
+ <arg value="jalview.xml.binding.uniprot"/>
+ </exec>
+</target>
+
+<target name="sourcedist" description="create jalview source distribution" depends="init">
+ <delete file="${source.dist.name}" />
+ <!-- temporary copy of source to update timestamps -->
+ <copy todir="_sourcedist">
+ <fileset dir=".">
+ <exclude name=".*" />
+ <exclude name="**/.*" />
+ <exclude name="*.class" />
+ <exclude name="**/*.class" />
+ <include name="LICENSE" />
+ <include name="README" />
+ <include name="build.xml" />
+ <include name="jalview-jalopy.xml" />
+ <include name="JalviewApplet.jpx" />
+ <include name="JalviewX.jpx" />
+ <include name="nbbuild.xml" />
+ <include name="nbproject/genfiles.properties" />
+ <include name="nbproject/project.properties" />
+ <include name="nbproject/project.xml" />
+ <include name="${sourceDir}/*.java" />
+ <include name="${sourceDir}/**/*.java" />
+ <include name="${sourceDir}/**/*.cdr" />
+ <include name="${libDir}/**/*" />
+ <include name="${resourceDir}/**/*" />
+ <include name="${helpDir}/**/*" />
+ <include name="appletlib/${jmolJar}" />
+ <include name="appletlib/${jsonSimple}" />
+ <include name="appletlib/${javaJson}" />
+ <exclude name="**/*locales" />
+ <exclude name="*locales/**" />
+ <exclude name="utils/InstallAnywhere/**Build.iap_xml" />
+ <exclude name="utils/InstallAnywhere/**Build*/**" />
+ <exclude name="utils/InstallAnywhere/**Build*/**" />
+ <exclude name="utils/InstallAnywhere/.build*.*/**" />
+ <exclude name="utils/InstallAnywhere/**locale*" />
+ <exclude name="utils/InstallAnywhere/**locale*/**" />
+ <exclude name="utils/InstallAnywhere/**locale*/**" />
+ <include name="${schemaDir}/**/*" />
+ <include name="utils/**/*" />
+ <include name="${docDir}/**/*" />
+ <include name="examples/**/*" />
+ </fileset>
+ </copy>
+
+ <tstamp prefix="build">
+ <format property="year" pattern="yyyy" />
+ </tstamp>
+ <!-- each replacetoken CDATA body must be on one line -
+ otherwise the pattern doesn't match -->
+ <replace value="${JALVIEW_VERSION}">
+ <replacetoken>
+ <![CDATA[$$Version-Rel$$]]>
+ </replacetoken>
+ <fileset dir="_sourcedist">
+ <include name="**/*" />
+ </fileset>
+ </replace>
+ <replace dir="_sourcedist" value="${build.year}">
+ <replacetoken>
+ <![CDATA[$$Year-Rel$$]]>
+ </replacetoken>
+ <fileset dir="_sourcedist">
+ <include name="**/*" />
+ </fileset>
+ </replace>
+
+ <tar destfile="${source.dist.name}" compression="gzip">
+ <tarfileset dir="_sourcedist/" prefix="jalview" preserveLeadingSlashes="true">
+ </tarfileset>
+ </tar>
+
+ <delete dir="_sourcedist" />
+</target>
+<target name="prepubapplet_1" depends="makeApplet">
+ <copy todir="${packageDir}/examples">
+ <fileset dir="examples">
+ <include name="**/*" />
+ <include name="javascript/*" />
+ <include name="jmol/*" />
+ </fileset>
+ <fileset dir=".">
+ <include name="${jalviewLiteJar}" />
+ </fileset>
+ <fileset dir="appletlib">
+ <include name="**/*" />
+ </fileset>
+ </copy>
+ <jar update="true" index="true" jarfile="${packageDir}/examples/${jalviewLiteJar}" />
+ <jar update="true" index="true" jarfile="${packageDir}/examples/${javaJson}" />
+ <jar update="true" index="true" jarfile="${packageDir}/examples/${jsonSimple}" />
+ <jar update="true" index="true" jarfile="${packageDir}/examples/${jmolJar}">
+ <manifest>
+ <attribute name="Application-Name" value="Jmol (bundled with JalviewLite)" />
+ <!-- <attribute name="Permissions" value="sandbox" /> -->
+ <!--<attribute name="Trusted-Lib" value="true" /> -->
+ <attribute name="Codebase" value="${applet.codebase}" />
+ <attribute name="Caller-Allowable-Codebase" value="${applet.caller-codebase}" />
+ </manifest>
+ </jar>
+
+ <presetdef name="ap_applet.jar">
+ <!-- build a signed applet with 'all-permissions' -
+ Needs 'param name="permissions' value="all-permissions"' in applet tag
+ JalviewLite+JmolApplet linked sequence/structure fails
+ Mixed code warnings are raised
+ -->
+ <jar update="true" index="true">
+ <manifest>
+ <attribute name="Application-Name" value="JalviewLite" />
+ <attribute name="Permissions" value="all-permissions" />
+ <attribute name="Codebase" value="${applet.codebase}" />
+ <attribute name="Caller-Allowable-Codebase" value="${applet.caller-codebase}" />
+ <attribute name="Application-Library-Allowable-Codebase" value="${applet.codebase}" />
+ </manifest>
+ </jar>
+ </presetdef>
+ <presetdef name="applet.jar">
+ <!-- build signed applet with sandbox permissions -
+ Needs 'param name="permissions' value="sandbox"' in applet tag
+ Preserves Pre-Java 1.7_u45 behavior once 'permissions' parameter added to applet tag
+ -->
+
+ <jar update="true" index="true">
+ <manifest>
+ <attribute name="Application-Name" value="JalviewLite" />
+ <attribute name="Permissions" value="sandbox" />
+ <attribute name="Codebase" value="${applet.codebase}" />
+ <attribute name="Caller-Allowable-Codebase" value="${applet.caller-codebase}" />
+ <attribute name="Application-Library-Allowable-Codebase" value="${applet.codebase}" />
+ </manifest>
+ </jar>
+ </presetdef>
+ <presetdef name="tl_applet.jar">
+ <!-- build signed applet with trusted library/trusted permissions -
+ Needs 'param name="permissions' value="all-permissions"' in applet tag
+ j1.7_45:
+ No mixed code warnings raised
+ Jmol/JalviewLite sequence/structure example doesn't link structures
+ Raises dialog asking user to allow page to control applet via LiveConnect javascript
+
+ -->
+
+ <jar update="true" index="true">
+ <manifest>
+ <attribute name="Application-Name" value="JalviewLite" />
+ <attribute name="Permissions" value="all-permissions" />
+ <attribute name="Codebase" value="${applet.codebase}" />
+ <attribute name="Trusted-Only" value="true" />
+ <attribute name="Trusted-Library" value="true" />
+ </manifest>
+ </jar>
+ </presetdef>
+ <presetdef name="to_applet.jar">
+ <!-- not fully test variant (yet) -->
+ <jar update="true" index="true">
+ <manifest>
+ <attribute name="Application-Name" value="JalviewLite" />
+ <attribute name="Permissions" value="all-permissions" />
+ <attribute name="Codebase" value="${applet.codebase}" />
+ <attribute name="Trusted-Only" value="true" />
+ </manifest>
+ </jar>
+ </presetdef>
+ <!-- create differently privileged artefacts -->
+ <copy file="${packageDir}/examples/${jalviewLiteJar}" tofile="${packageDir}/examples/u_${jalviewLiteJar}" />
+ <copy file="${packageDir}/examples/${jmolJar}" tofile="${packageDir}/examples/u_${jmolJar}" overwrite="true" />
+ <copy file="${packageDir}/examples/${javaJson}" tofile="${packageDir}/examples/u_${javaJson}" overwrite="true" />
+ <copy file="${packageDir}/examples/${jsonSimple}" tofile="${packageDir}/examples/u_${jsonSimple}" overwrite="true" />
+ <copy file="${packageDir}/examples/${jalviewLiteJar}" tofile="${packageDir}/examples/ap_${jalviewLiteJar}" />
+ <copy file="${packageDir}/examples/${jmolJar}" tofile="${packageDir}/examples/ap_${jmolJar}" />
+ <copy file="${packageDir}/examples/${javaJson}" tofile="${packageDir}/examples/ap_${javaJson}" />
+ <copy file="${packageDir}/examples/${jsonSimple}" tofile="${packageDir}/examples/ap_${jsonSimple}" />
+ <ap_applet.jar jarfile="${packageDir}/examples/ap_${jalviewLiteJar}" />
+ <ap_applet.jar jarfile="${packageDir}/examples/ap_${jmolJar}" />
+ <ap_applet.jar jarfile="${packageDir}/examples/ap_${javaJson}" />
+ <ap_applet.jar jarfile="${packageDir}/examples/ap_${jsonSimple}" />
+ <copy file="${packageDir}/examples/${jalviewLiteJar}" tofile="${packageDir}/examples/tl_${jalviewLiteJar}" />
+ <copy file="${packageDir}/examples/${jmolJar}" tofile="${packageDir}/examples/tl_${jmolJar}" />
+ <copy file="${packageDir}/examples/${javaJson}" tofile="${packageDir}/examples/tl_${javaJson}" />
+ <copy file="${packageDir}/examples/${jsonSimple}" tofile="${packageDir}/examples/tl_${jsonSimple}" />
+ <tl_applet.jar jarfile="${packageDir}/examples/tl_${jalviewLiteJar}" />
+ <tl_applet.jar jarfile="${packageDir}/examples/tl_${jmolJar}" />
+ <tl_applet.jar jarfile="${packageDir}/examples/tl_${javaJson}" />
+ <tl_applet.jar jarfile="${packageDir}/examples/tl_${jsonSimple}" />
+ <copy file="${packageDir}/examples/${jalviewLiteJar}" tofile="${packageDir}/examples/to_${jalviewLiteJar}" />
+ <copy file="${packageDir}/examples/${jmolJar}" tofile="${packageDir}/examples/to_${jmolJar}" />
+ <copy file="${packageDir}/examples/${javaJson}" tofile="${packageDir}/examples/to_${javaJson}" />
+ <copy file="${packageDir}/examples/${jsonSimple}" tofile="${packageDir}/examples/to_${jsonSimple}" />
+ <to_applet.jar jarfile="${packageDir}/examples/to_${jalviewLiteJar}" />
+ <to_applet.jar jarfile="${packageDir}/examples/to_${jmolJar}" />
+ <to_applet.jar jarfile="${packageDir}/examples/to_${javaJson}" />
+ <to_applet.jar jarfile="${packageDir}/examples/to_${jsonSimple}" />
+ <!-- finally, create manifest for original jars -->
+ <applet.jar jarfile="${packageDir}/examples/${jalviewLiteJar}" />
+ <applet.jar jarfile="${packageDir}/examples/${jmolJar}" />
+ <applet.jar jarfile="${packageDir}/examples/${javaJson}" />
+ <applet.jar jarfile="${packageDir}/examples/${jsonSimple}" />
+
+ <!-- todo - write examples/downloads for alternate versions of the applet
+ probably don't need to do this now since we don't have alternate versions anymore !-->
+</target>
+<target name="-signapplet" depends="prepubapplet_1">
+ <fileset id="signappletjarset" dir="${packageDir}/examples">
+ <exclude name="u_*.jar" />
+ <include name="${jalviewLiteJar}" />
+ <include name="${jmolJar}" />
+ <include name="${javaJson}" />
+ <include name="${jsonSimple}" />
+ <include name="to_${jalviewLiteJar}" />
+ <include name="to_${jmolJar}" />
+ <include name="to_${javaJson}" />
+ <include name="to_${jsonSimple}" />
+ <include name="tl_${jalviewLiteJar}" />
+ <include name="tl_${jmolJar}" />
+ <include name="tl_${javaJson}" />
+ <include name="tl_${jsonSimple}" />
+ <include name="ap_${jalviewLiteJar}" />
+ <include name="ap_${jmolJar}" />
+ <include name="ap_${javaJson}" />
+ <include name="ap_${jsonSimple}" />
+ </fileset>
+</target>
+<target name="-signappletnotsa" if:blank="timestamp" depends="-signapplet" unless="nosign">
+ <signjar storepass="${jalview.keystore.pass}" keypass="${jalview.key.pass}" keystore="${jalview.keystore}" alias="${jalview.key}" lazy="false" verbose="false">
+ <fileset refid="signappletjarset" />
+ </signjar>
+</target>
+
+<target name="-signapplettsa" if="timestamp" depends="-signapplet" unless="nosign">
+ <signjar storepass="${jalview.keystore.pass}" keypass="${jalview.key.pass}" keystore="${jalview.keystore}" alias="${jalview.key}" lazy="false" verbose="false" tsaproxyhost="${proxyHost}" tsaproxyport="${proxyPort}" tsaurl="${jalview.tsaurl}">
+ <fileset refid="signappletjarset" />
+ </signjar>
+</target>
+
+<target name="signApplet" description="internal target to sign applet" depends="-signappletnotsa,-signapplettsa" />
+<target name="pubapplet" description="Dummy target to keep legacy Jalview build system happy. We don't actually publish the applet anymore."/>
+
+<target name="_pubapplet" description="installs the jalviewLite applet and dependent jars into an applet examples directory built under ${outputDir}" depends="makeApplet, signApplet">
+
+ <!-- bizarre bug causes JmolApplet to always get signed, even if excluded from above. so copy explicitly -->
+ <copy file="appletlib/${jmolJar}" tofile="${packageDir}/examples/u_${jmolJar}" overwrite="true" />
+ <copy file="appletlib/${jsonSimple}" tofile="${packageDir}/examples/u_${jsonSimple}" overwrite="true" />
+ <copy file="appletlib/${javaJson}" tofile="${packageDir}/examples/u_${javaJson}" overwrite="true" />
+ <!-- finally, replace any launchApp servlet tags with a version specification -->
+ <replace value="http://www.jalview.org/services/launchApp?version=${JALVIEW_VERSION}"">
+ <replacetoken>
+ <![CDATA[http://www.jalview.org/services/launchApp"]]>
+ </replacetoken>
+ <fileset dir="${packageDir}/examples">
+ <include name="**/*.html" />
+ </fileset>
+ </replace>
+ <replace value="http://www.jalview.org/services/launchApp?version=${JALVIEW_VERSION}'">
+ <replacetoken>
+ <![CDATA[http://www.jalview.org/services/launchApp']]>
+ </replacetoken>
+ <fileset dir="${packageDir}/examples">
+ <include name="**/*.html" />
+ </fileset>
+ </replace>
+
+</target>
+<target name="sourcedoc" description="Create jalview source documentation pages" depends="init">
+ <javadoc destdir="${javadocDir}">
+ <packageset dir="${sourceDir}" includes="jalview/*,MCView/*">
+ </packageset>
+ </javadoc>
+</target>
+<target name="linkcheck" depends="init,prepare">
+ <javac srcdir="utils" destdir="utils" includes="HelpLinksChecker.java"/>
+ <java fork="true" dir="${helpDir}" classpath="utils" classname="HelpLinksChecker" failonerror="true">
+ <arg file="${helpDir}"/>
+ <arg value="-nointernet" />
+ </java>
+</target>
+
+<target name="eclipse-install" depends="init,prepare">
+
+ <property name="eclipseTempFile" value="eclipse-jee-oxygen-R-linux-gtk-x86_64.tar.gz"/>
+ <property name="eclipseInstallURL" value="http://mirror.csclub.uwaterloo.ca/eclipse/technology/epp/downloads/release/oxygen/R/eclipse-jee-oxygen-R-linux-gtk-x86_64.tar.gz"/>
+ <property name="java2scriptURL" value="https://github.com/BobHanson/java2script/blob/master/sources/net.sf.j2s.core/dist/dropins/net.sf.j2s.core.jar?raw=true"/>
+
+ <get url="${eclipseInstallURL}" dest="${eclipseTempFile}"/>
+ <untar compression="gzip" src="${eclipseTempFile}" dest="${eclipse-inst}"/>
+
+ <!-- not needed since we ship transpiler with source
+ <get url="${java2scriptURL}" dest="eclipse-inst/dropins/net.sf.j2s.core.jar" /> -->
+
+</target>
+
+<target name="build-site" depends="init,prepare,compile-site,unzip-to-site,make-j2s-cores">
+ <!-- tarball -->
+ <tar compression="gzip" destfile="site.tar.gz">
+ <tarfileset dir="site" />
+ </tar>
+</target>
+<target name="prepare-site" depends="init,prepare">
+ <property name="swingjsdir" value="swingjs"/>
+ <property name="eclipse-inst" value="/home/bamboo/buildtools/eclipse/eclipse-js"/>
+ <property name="eclipse-exec" value="${eclipse-inst}/eclipse"/>
+ <property name="site" value="site"/>
+ <!-- where the eclipse js workspace has been initialised -->
+ <property name="eclipse-work" value="/home/bamboo/buildtools/eclipse/eclipse-js-workspace"/>
+ <!-- git repository linked to project in workspace -->
+ <property name="eclipse-workrepo" value="/home/bamboo/buildtools/eclipse/eclipse-js-workspace/jalview-js"/>
+</target>
+ <target name="clean-site" depends="prepare-site">
+ <delete dir="${eclipse-workrepo}/${site}"/>
+ <mkdir dir="${eclipse-workrepo}/${site}"/>
+ </target>
+<target name="compile-site" depends="prepare-site,clean-site">
+ <!-- update transpiler -->
+ <copy file="${swingjsdir}/net.sf.j2s.core.jar" todir="${eclipse-inst}/dropins" overwrite="true" failonerror="true"/>
+ <!-- update the git repo linked to the eclipse workspace -->
+ <exec executable="/usr/bin/git" outputproperty="git.commit" failifexecutionfails="true">
+ <arg value="rev-parse" />
+ <arg value="--short" />
+ <arg value="HEAD" />
+ </exec>
+ <!-- update and checkout the same commit in the workspace project -->
+ <exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
+ <arg value="reset" />
+ <arg value="--hard" />
+ </exec>
+ <exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
+ <arg value="pull" />
+ </exec>
+ <exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
+ <arg value="checkout" />
+ <arg value="${git.commit}" />
+ </exec>
+ <!-- custom classpath for .js builds -->
+ <copy file=".classpath.js" tofile="${eclipse-workrepo}/.classpath" overwrite="true"/>
+ <!-- clean eclipse log -->
+ <delete file="${eclipse-work}/.metadata/.log"/>
+
+ <!-- execute the eclipse build - the build may fail but valid javascript may still be produced, so we ignore return codes -->
+ <exec executable="${eclipse-exec}" failonerror="no">
+ <arg value="-nosplash"/>
+ <arg value="--launcher.suppressErrors"/>
+ <arg value="-application"/>
+ <arg value="org.eclipse.jdt.apt.core.aptBuild"/>
+ <arg value="-data"/>
+ <arg value="${eclipse-work}"/>
+ </exec>
+ <!-- report log -->
+ <exec executable="/bin/cat">
+ <arg value="${eclipse-work}/.metadata/.log"/>
+ </exec>
+ <!-- TODO: run jslint and something else here to check we have a complete set of .js files for java -->
+ <!-- possibly compare timestamps between .js files and their mate in source - any newer or not present triggers a new build -->
+ <!-- <mkdir dir="${packageDir}/${site}" /> -->
+ <!-- <property name="swingjs.zipurl" value="https://github.com/BobHanson/java2script/blob/master/sources/net.sf.j2s.java.core/dist/SwingJS-site.zip?raw=true" /> -->
+
+ <!-- and reset the .classpath -->
+ <exec executable="/usr/bin/git" failifexecutionfails="true" dir="${eclipse-workrepo}">
+ <arg value="checkout" />
+ <arg value="${git.commit}"/>
+ <arg value="--"/>
+ <arg value=".classpath" />
+ </exec>
+
+ <!-- finally copy artefacts from eclipse project checkout to the build site -->
+ <copy todir="${site}">
+ <fileset dir="${eclipse-workrepo}/site"/>
+ </copy>
+</target>
+<target name="unzip-to-site" depends="prepare-site">
+ <ant antfile="build-site.xml"/>
+</target>
+
+ <target name="make-j2s-cores" depends="">
+ <ant antfile="buildcore.xml" target="build-all-cores"/>
+ </target>