Permalink
Browse files

ant build script

git-svn-id: https://hadoopdb.svn.sourceforge.net/svnroot/hadoopdb/trunk@3 2ab80ee8-dcc6-4802-a23e-3bfff869ab2a
  • Loading branch information...
1 parent e03853e commit 29c611e44330891ccd86504449777b9a46c2e36b kbajda committed Jul 20, 2009
Showing with 63 additions and 0 deletions.
  1. +4 −0 build.properties
  2. +59 −0 build.xml
View
@@ -0,0 +1,4 @@
+src=./src/java
+classes=./build/classes
+lib=./lib
+build=./build
View
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<project name="HadoopDB" default="build" basedir=".">
+
+ <property file="build.properties"/>
+ <property file="local.build.properties"/>
+
+ <!-- Hadoop and Hive jars should be there -->
+ <path id="compile.classpath">
+ <fileset dir="${lib}">
+ <include name="**/*.jar"/>
+ </fileset>
+ </path>
+
+
+ <target name="build" depends="compile,jar">
+ </target>
+
+ <target name="compile" description="Compiles the source code" depends="deleteclasses">
+
+ <mkdir dir="${build}"/>
+ <mkdir dir="${classes}"/>
+
+ <!-- Compile generated sources -->
+ <javac debug="${debug}"
+ verbose="${verbose}"
+ destdir="${classes}"
+ srcdir="${src}"
+ includes="**/*.java"
+ classpathref="compile.classpath"
+ deprecation="false"
+ optimize="false"
+ fork="no"
+ failonerror="true">
+ </javac>
+ </target>
+
+ <target name="jar" description="Creates a jar">
+
+ <mkdir dir="${build}"/>
+
+ <jar jarfile="${build}/hadoopdb.jar">
+ <fileset dir="${classes}">
+ <include name="**/*.class"/>
+ </fileset>
+ </jar>
+ </target>
+
+
+ <target name="clean" description="Delete all build files">
+ <delete dir="${build}"/>
+ </target>
+
+
+ <target name="deleteclasses" description="Delete all compiled classes">
+ <delete dir="${classes}"/>
+ </target>
+
+</project>

0 comments on commit 29c611e

Please sign in to comment.