2008-10-31 13:33:02 -04:00
|
|
|
<?xml version="1.0"?>
|
|
|
|
|
|
|
|
<!--
|
|
|
|
Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
contributor license agreements. See the NOTICE file distributed with
|
|
|
|
this work for additional information regarding copyright ownership.
|
|
|
|
The ASF licenses this file to You under the Apache License, Version 2.0
|
|
|
|
the "License"); you may not use this file except in compliance with
|
|
|
|
the License. You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
-->
|
|
|
|
|
|
|
|
<project name="solr-velocity" default="build">
|
|
|
|
|
|
|
|
<property name="solr-path" value="../.." />
|
|
|
|
|
|
|
|
<import file="../../common-build.xml"/>
|
|
|
|
|
|
|
|
<description>
|
|
|
|
Solritas: Velocity Response Writer
|
|
|
|
</description>
|
|
|
|
|
|
|
|
<path id="common.classpath">
|
2008-12-07 14:07:11 -05:00
|
|
|
<pathelement location="${solr-path}/build/solrj" />
|
|
|
|
<pathelement location="${solr-path}/build/solr" />
|
2008-10-31 13:33:02 -04:00
|
|
|
<fileset dir="src/main/solr/lib" includes="*.jar"/>
|
|
|
|
<fileset dir="${solr-path}/lib" includes="*.jar"></fileset>
|
|
|
|
</path>
|
|
|
|
|
|
|
|
<path id="test.classpath">
|
|
|
|
<path refid="common.classpath" />
|
|
|
|
<pathelement path="target/classes" />
|
|
|
|
<pathelement path="target/test-classes" />
|
|
|
|
<pathelement path="${java.class.path}"/>
|
|
|
|
</path>
|
|
|
|
|
|
|
|
<target name="clean">
|
|
|
|
<delete failonerror="false" dir="target"/>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="init">
|
|
|
|
<mkdir dir="target/classes"/>
|
|
|
|
<mkdir dir="${build.javadoc}" />
|
|
|
|
<ant dir="../../" inheritall="false" target="compile" />
|
|
|
|
<ant dir="../../" inheritall="false" target="make-manifest" />
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="compile" depends="init">
|
|
|
|
<solr-javac destdir="target/classes"
|
|
|
|
classpathref="common.classpath">
|
|
|
|
<src path="src/main/java" />
|
|
|
|
</solr-javac>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="build" depends="compile">
|
2009-09-29 05:19:40 -04:00
|
|
|
<solr-jar destfile="target/${fullnamever}.jar" basedir="target/classes"
|
2008-11-01 00:49:56 -04:00
|
|
|
manifest="${common.dir}/${dest}/META-INF/MANIFEST.MF">
|
|
|
|
<fileset dir="src/main/java" excludes="**/*.java"/>
|
|
|
|
</solr-jar>
|
2008-10-31 13:33:02 -04:00
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="compileTests" depends="compile">
|
|
|
|
<solr-javac destdir="target/test-classes"
|
|
|
|
classpathref="test.classpath">
|
|
|
|
<src path="src/test/java" />
|
|
|
|
</solr-javac>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="test" depends="compileTests">
|
|
|
|
<mkdir dir="${junit.output.dir}"/>
|
|
|
|
|
|
|
|
<junit printsummary="on"
|
|
|
|
haltonfailure="no"
|
|
|
|
errorProperty="tests.failed"
|
|
|
|
failureProperty="tests.failed"
|
|
|
|
dir="src/test/resources/"
|
|
|
|
>
|
|
|
|
<formatter type="brief" usefile="false" if="junit.details"/>
|
|
|
|
<classpath refid="test.classpath"/>
|
|
|
|
<formatter type="xml"/>
|
|
|
|
<batchtest fork="yes" todir="${junit.output.dir}" unless="testcase">
|
|
|
|
<fileset dir="src/test/java" includes="${junit.includes}"/>
|
|
|
|
</batchtest>
|
|
|
|
<batchtest fork="yes" todir="${junit.output.dir}" if="testcase">
|
|
|
|
<fileset dir="src/test/java" includes="**/${testcase}.java"/>
|
|
|
|
</batchtest>
|
|
|
|
</junit>
|
|
|
|
|
|
|
|
<fail if="tests.failed">Tests failed!</fail>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="dist" depends="build">
|
2009-09-29 05:19:40 -04:00
|
|
|
<copy file="target/${fullnamever}.jar" todir="${common.dir}/dist/${fullnamever}.jar" />
|
2008-10-31 13:33:02 -04:00
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="javadoc">
|
|
|
|
<sequential>
|
|
|
|
<mkdir dir="${build.javadoc}/contrib-${name}"/>
|
|
|
|
|
|
|
|
<path id="javadoc.classpath">
|
|
|
|
<path refid="common.classpath"/>
|
|
|
|
</path>
|
|
|
|
|
|
|
|
<invoke-javadoc
|
|
|
|
destdir="${build.javadoc}/contrib-${name}"
|
|
|
|
title="${Name} ${version} contrib-${fullnamever} API">
|
|
|
|
<sources>
|
|
|
|
<packageset dir="src/main/java"/>
|
|
|
|
</sources>
|
|
|
|
</invoke-javadoc>
|
|
|
|
</sequential>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="run">
|
|
|
|
<!-- TODO: Autolaunch Solr -->
|
|
|
|
</target>
|
|
|
|
|
2008-12-06 08:04:26 -05:00
|
|
|
<target name="example" depends="build"/>
|
|
|
|
|
2008-10-31 13:33:02 -04:00
|
|
|
</project>
|