[hibernate-commits] Hibernate SVN: r15325 - common/branches/v3_2_1_GA_CP.
hibernate-commits at lists.jboss.org
hibernate-commits at lists.jboss.org
Fri Oct 10 23:24:18 EDT 2008
Author: gbadner
Date: 2008-10-10 23:24:18 -0400 (Fri, 10 Oct 2008)
New Revision: 15325
Modified:
common/branches/v3_2_1_GA_CP/common-build.xml
Log:
JBPAPP-931 : Updates to common-build.xml so the same version can be used for both annotations and entitymanager
Modified: common/branches/v3_2_1_GA_CP/common-build.xml
===================================================================
--- common/branches/v3_2_1_GA_CP/common-build.xml 2008-10-11 03:06:40 UTC (rev 15324)
+++ common/branches/v3_2_1_GA_CP/common-build.xml 2008-10-11 03:24:18 UTC (rev 15325)
@@ -18,6 +18,7 @@
<property name="testclasses.dir" location="${build.dir}/testclasses"/>
<property name="dist.target.dir" location="target"/>
<property name="dist.dir" location="${dist.target.dir}/${name}"/>
+ <property name="test.out.dir" value="test_output"/>
<property name="instrumenttest.out.dir" value="instrumenttestout"/>
<property name="doc.dir" location="doc"/>
<property name="doc.api.dir" location="${doc.dir}/api"/>
@@ -33,18 +34,18 @@
<property name="jar.file.name" value="${dist.dir}/${jar.name}.jar"/>
<property name="jartest.file.name" value="${dist.dir}/${jar.name}-tests.jar"/>
- <property name="javadoc" value="http://java.sun.com/j2se/1.4/docs/api"/>
+ <property name="javac.source" value="1.5"/>
+ <property name="javac.target" value="1.5"/>
+ <property name="javadoc" value="http://java.sun.com/j2se/${javac.source}/docs/api"/>
<property name="javac.debug" value="on"/>
<property name="javac.optimize" value="off"/>
-
<!-- set Hibernate core related properties -->
- <property name="hibernate-core.home" location="${common-build.basedir}/../../hibernate-3.2"/>
- <property name="hibernate-core.jar" location="${hibernate-core.home}/hibernate3.jar"/>
+ <property name="hibernate-core.home" location="${common-build.basedir}/../core"/>
+ <property name="hibernate-core.jar" location="${hibernate-core.home}/build/hibernate3.jar"/>
<property name="hibernate-core.lib.dir" location="${hibernate-core.home}/lib"/>
- <property name="hibernate-core.jdbc.dir" location="${hibernate-core.home}/lib"/> <!-- for some reason jdbc.dir is renamed to lib instead of jdbc when doing a dist of hibernate3 -->
- <property name="hibernate-core.doc.api" location="${hibernate-core.home}/doc/api"/>
<property name="hibernate-cvs.doc.reference" location="${common-build.basedir}/../../Hibernate3/doc/reference"/>
+ <property name="hibernate-annotations.home" location="${common-build.basedir}/../annotations"/>
<!--
Explicitly define tasks from ant..
@@ -76,7 +77,7 @@
</classpath>
</taskdef>
- <path id="lib.class.path">
+ <!--<path id="lib.class.path">
<path location="${hibernate-core.jar}"></path>
<fileset dir="${hibernate-core.lib.dir}">
<include name="*.jar"/>
@@ -85,7 +86,7 @@
<include name="*.jar"/>
</fileset>
<pathelement path="${clover.jar}"/>
- </path>
+ </path>-->
<patternset id="support.files">
<include name="**/*.jpg"/>
@@ -125,7 +126,7 @@
<property name="clover.jar" value="${ant.home}/lib/clover.jar"/>
<taskdef resource="clovertasks"/>
- <path id="junit.classpath">
+ <!--<path id="junit.classpath">
<fileset dir="${lib.dir}">
<include name="*.jar"/>
</fileset>
@@ -134,7 +135,7 @@
<path refid="lib.class.path"/>
<path refid="junit.moduleclasspath"/>
<path location="${clover.jar}"/>
- </path>
+ </path>-->
<!-- Clover tasks -->
<target name="with.clover">
@@ -193,8 +194,8 @@
value="org.eclipse.jdt.core.JDTCompilerAdapter"
classpath="${java.class.path}"/>
<javac
- target="1.4"
- source="1.4"
+ source="${javac.source}"
+ target="${javac.target}"
srcdir="${src.dir}"
destdir="${classes.dir}"
classpathref="lib.class.path"
@@ -211,8 +212,8 @@
value="org.eclipse.jdt.core.JDTCompilerAdapter"
classpath="${java.class.path}"/>
<javac
- target="1.4"
- source="1.4"
+ source="${javac.source}"
+ target="${javac.target}"
destdir="${testclasses.dir}"
classpathref="junit.classpath"
debug="${javac.debug}"
@@ -222,31 +223,23 @@
</javac>
</target>
- <target name="instrument" depends="compiletest"
+ <target name="instrument" depends="compiletest"
description="Instrument the persistent classes"> <!-- depends="jar" -->
-
- <taskdef name="instrument" classname="org.hibernate.tool.instrument.InstrumentTask">
+ <property name="testclasses.test.dir" value="${testclasses.dir}/org/hibernate/test"/>
+ <taskdef name="instrument" classname="org.hibernate.tool.instrument.javassist.InstrumentTask">
<classpath path="${classes.dir}"/>
- <classpath path="${testclasses.dir}"/>
- <classpath refid="lib.class.path"/>
+ <classpath path="${testclasses.dir}"/>
+ <classpath refid="lib.class.path"/>
</taskdef>
<instrument verbose="true">
- <fileset dir="${testclasses.dir}/org/hibernate/test">
+ <fileset dir="${testclasses.test.dir}">
<include name="**/*.class"/>
<exclude name="**/*Test$*.class"/>
<exclude name="**/*Test.class"/>
<exclude name="**/*Tests.class"/>
</fileset>
</instrument>
-
- <!-- jar jarfile="${build.dir}/instrumented-classes.jar">
- <fileset dir="${testclasses.dir}">
- <include name="org/hibernate/test/**/*.class"/>
- <exclude name="org/hibernate/test/**/*Test.class"/>
- </fileset>
- </jar -->
-
</target>
<target name="copytest" description="Copy tests to dist dir" if="copy.test" >
@@ -298,11 +291,6 @@
</copy>
</target>
- <target name="jar" depends="compile" description="Build the distribution .jar file">
- <mkdir dir="${dist.dir}"/>
- <jar filesetmanifest="merge" jarfile="${jar.file.name}" basedir="${classes.dir}"/>
- </target>
-
<target name="jartest" depends="compiletest" description="Build the distribution .jar file">
<mkdir dir="${dist.dir}"/>
<jar filesetmanifest="merge" jarfile="${jartest.file.name}" basedir="${testclasses.dir}"/>
@@ -320,9 +308,8 @@
protected="true"
version="true"
windowtitle="${Name} API Documentation"
- Overview="${doc.api.dir}/package.html"
doctitle="${Name} API Documentation"
- stylesheetfile="${hibernate-core.doc.api}/jdstyle.css"
+ stylesheetfile="${doc.api.dir}/jdstyle.css"
link="${javadoc}">
<packageset dir="${src.dir}" defaultexcludes="yes" >
<include name="**/*" />
@@ -374,43 +361,29 @@
<echo message="user.language=${user.language}"/>
</target>
- <target name="junit" depends="compiletest">
- <mkdir dir="test_output"/>
- <junit printsummary="yes" haltonfailure="yes" forkmode="once">
- <classpath refid="junit.classpath"/>
- <formatter type="plain"/>
- <formatter type="xml"/>
- <batchtest fork="yes" todir="test_output" haltonfailure="no">
- <fileset refid="junit.batchtestset"/>
- </batchtest>
- </junit>
- </target>
-
<target name="junitinstrument" depends="compiletest,instrument"
description="Run the instrument test suite (requires driver.jar property)">
- <mkdir dir="${instrumenttest.out.dir}"/>
- <junit printsummary="yes" haltonfailure="yes" dir="${basedir}"
- maxmemory="256M" fork="yes" forkmode="perBatch">
- <classpath refid="junit.classpath"/>
- <formatter type="plain"/>
- <formatter type="xml"/>
- <batchtest todir="${instrumenttest.out.dir}" haltonfailure="no">
- <fileset dir="${classes.dir}">
- <include name="org/hibernate/test/**/*Test.class"/>
- </fileset>
- </batchtest>
- </junit>
- </target>
+ <antcall target="junit" inheritall="true">
+ <param name="test.out.dir" value="${instrumenttest.out.dir}"/>
+ </antcall>
+ </target>
<target name="junitreport" depends="">
- <junitreport todir="./test_output">
- <fileset dir="test_output">
+ <junitreport todir="${test.out.dir}">
+ <fileset dir="${test.out.dir}">
<include name="TEST-*.xml"/>
</fileset>
- <report format="frames" todir="./test_output"/>
+ <report format="frames" todir="${test.out.dir}"/>
</junitreport>
</target>
+ <target name="junitinstrumentreport" depends="">
+ <antcall target="junitreport" inheritall="true">
+ <param name="test.out.dir" value="${instrumenttest.out.dir}"/>
+ </antcall>
+ </target>
+
+
<target name="run" depends="compile" description="Run Hibernate Console">
<java classname="org.hibernate.console.Start" classpathref="lib.class.path" fork="true">
<classpath>
@@ -443,4 +416,4 @@
<cvs command="-q diff -u -N" output="patch.txt"/>
</target>
-</project>
\ No newline at end of file
+</project>
More information about the hibernate-commits
mailing list