Permalink
Fetching contributors…
Cannot retrieve contributors at this time
148 lines (123 sloc) 4.9 KB
<?xml version="1.0"?>
<!-- ===================================================== -->
<!-- RF-SRC Public Build File Apache Ant version 1.10.0 -->
<!-- ===================================================== -->
<project name="RF-SRC Public" basedir="." default="usage" >
<property name="project.pkg.name" value="randomForestSRC"/>
<property name="project.version" value="2.7.0"/>
<property name="project.build" value="bld20180817"/>
<property name="minimum.version" value="2.3.0"/>
<property name="http.prefix" value="http://"/>
<property name="https.prefix" value="https://"/>
<property environment="env"/>
<import file="build.cran.xml"/>
<import file="build.spark.xml"/>
<!--
========================================================================
Internal Target: INIT
========================================================================
-->
<target name="init">
<tstamp>
<format property="DSTAMP" pattern="yyyy-MM-dd"/>
<format property="TSTAMP" pattern="hh:mm:ss"/>
</tstamp>
<echo message="--------- ${project.pkg.name} ---------"/>
<echo message=""/>
<echo message="Version: ${project.version}"/>
<echo message="Build: ${project.build}"/>
<echo message=""/>
<echo message=" Date: ${DSTAMP}"/>
<echo message=" Time: ${TSTAMP}"/>
<echo message=""/>
<echo message="Platform Details:"/>
<echo message=" OS name ${os.name}"/>
<echo message=" OS version ${os.version}"/>
<echo message=" OS arch ${os.arch}"/>
<echo message=" Java arch ${sun.arch.data.model}"/>
</target>
<!--
========================================================================
Internal Targets: Customization for Operating System
========================================================================
-->
<target name="os-prep" depends="win10-prep,lin-prep,mac-prep"/>
<target name="win10-prep" depends="checkOS" if="is-win10">
<property name="sep" value="\"/>
<property name="scriptExtension" value=".cmd"/>
<property name="scriptFileCommentLine" value="@echo off"/>
<property name="scriptFileExitLine" value="exit /b"/>
<property name="cranArchive" value=".zip"/>
<echo message="Customization for Windows 10"/>
</target>
<target name="lin-prep" depends="checkOS" if="is-lin">
<property name="sep" value="/"/>
<property name="scriptExtension" value=".sh"/>
<property name="scriptFileCommentLine" value="#!/bin/bash"/>
<property name="scriptFileExitLine" value="exit 0"/>
<property name="cranArchive" value="_R_x86_64-pc-linux-gnu.tar.gz"/>
<echo message="Customization for Linux"/>
</target>
<target name="mac-prep" depends="checkOS" if="is-mac">
<property name="sep" value="/"/>
<property name="scriptExtension" value=".sh"/>
<property name="scriptFileCommentLine" value="#!/bin/bash"/>
<property name="scriptFileExitLine" value="exit 0"/>
<property name="cranArchive" value=".tgz"/>
<echo message="Customization for Mac OS X"/>
</target>
<target name="checkOS">
<condition property="is-win10">
<os name="Windows 10"/>
</condition>
<condition property="is-lin">
<os name="Linux"/>
</condition>
<condition property="is-mac">
<os name="Mac OS X"/>
</condition>
</target>
<!--
========================================================================
CLEAN targets, Entry Point
========================================================================
-->
<target name="clean" depends="init, clean-cran, clean-spark">
<delete dir="target"/>
</target>
<target name="clean-cran" depends="init">
<delete dir="target/cran"/>
</target>
<target name="clean-spark" depends="init">
<delete dir="target/spark"/>
</target>
<!--
========================================================================
Help on usage. List available targets
========================================================================
-->
<target name="usage" depends="init">
<echo message=""/>
<echo message=" Available targets are:"/>
<echo message=""/>
<echo message=" clean"/>
<echo message=" clean-cran"/>
<echo message=" clean-spark"/>
<echo message=" --> delete the target trees"/>
<echo message=""/>
<echo message=" source-cran"/>
<echo message=" --> create the CRAN source package"/>
<echo message=""/>
<echo message=" install-cran-mac"/>
<echo message=" install-cran-win"/>
<echo message=" install-cran-lin"/>
<echo message=" --> install the parallel CRAN package"/>
<echo message=""/>
<echo message=" source-spark"/>
<echo message=" --> create the Spark source tree"/>
<echo message=""/>
<echo message=" build-spark"/>
<echo message=" --> create the Spark source and build the Spark target"/>
<echo message=""/>
</target>
</project>