[hibernate-commits] Hibernate SVN: r13495 - entitymanager/tags/v3_3_0_GA.

hibernate-commits at lists.jboss.org hibernate-commits at lists.jboss.org
Wed Aug 15 20:33:17 EDT 2007


Author: epbernard
Date: 2007-08-15 20:33:17 -0400 (Wed, 15 Aug 2007)
New Revision: 13495

Added:
   entitymanager/tags/v3_3_0_GA/build.xml
Log:
Move entitymanager tags/entitymanager_v3_3_0_GA to the new structure (v3_3_0_GA)

Copied: entitymanager/tags/v3_3_0_GA/build.xml (from rev 13494, tags/entitymanager_v3_3_0_GA/HibernateExt/entitymanager/build.xml)
===================================================================
--- entitymanager/tags/v3_3_0_GA/build.xml	                        (rev 0)
+++ entitymanager/tags/v3_3_0_GA/build.xml	2007-08-16 00:33:17 UTC (rev 13495)
@@ -0,0 +1,378 @@
+<!--
+
+  Hibernate Annotations ANT build script.
+
+  You need JDK 5.0 installed to build Hibernate EntityManager.
+
+-->
+
+<project name="HibernateEntityManager" default="dist" basedir=".">
+
+    <!-- Give user a chance to override without editing this file
+       (and without typing -D each time it compiles it) -->
+    <property file="build.properties"/>
+    <property file="${user.home}/.ant.properties"/>
+
+    <!-- Name of project and version, used to create filenames -->
+    <property name="Name" value="Hibernate EntityManager"/>
+    <property name="name" value="hibernate-entitymanager"/>
+    <property name="version" value="3.3.0.GA"/>
+    <property name="javadoc.packagenames" value="org.hibernate.ejb.*"/>
+    <property name="jdbc.dir" value="jdbc"/>
+    <property name="copy.test" value="true"/>
+	<property name="javac.source" value="1.5"/>
+	<property name="javac.target" value="1.5"/>
+    <property name="common.dir" value="../common"/>
+
+    <available property="jpa-present" file="${basedir}/../jpa-api" type="dir"/>
+    <property name="jpa-api.jar" value="${basedir}/../jpa-api/build/ejb3-persistence.jar"/>
+    <property name="annotations.jar"
+                  value="${basedir}/../annotations/target/hibernate-annotations/hibernate-annotations.jar"/>
+    <property name="validator.jar"
+                      value="${basedir}/../validator/target/hibernate-validator/hibernate-validator.jar"/>
+    <property name="commons-annotations.jar"
+                  value="${basedir}/../commons-annotations/target/hibernate-commons-annotations/hibernate-commons-annotations.jar"/>
+
+    <import file="${common.dir}/common-build.xml"/>
+	<property name="jpa-javadoc.dir" value="${dist.doc.dir}/jpa-api"/>
+
+
+    <property name="resources.dir" value="src/resources"/>
+    <property name="testresources.dir" value="src/test-resources"/>
+    <property name="build.testresources.dir" value="${build.dir}/testresources"/>
+    <property name="build.temp.dir" value="${build.dir}/temp"/>
+
+    <path id="lib.moduleclass.path">
+		<pathelement location="${jpa-api.jar}"/>
+		<pathelement location="${commons-annotations.jar}"/>
+        <pathelement location="${annotations.jar}"/>
+        <pathelement location="${validator.jar}"/>
+    </path>
+	<path id="junit.moduleclasspath">
+		<pathelement location="${src.dir}"/>
+		<pathelement location="${test.dir}"/>
+        <fileset dir="${jdbc.dir}">
+			<include name="*.jar"/>
+			<include name="*.zip"/>
+		</fileset>
+        <fileset dir="${lib.dir}/test">
+			<include name="*.jar"/>
+			<include name="*.zip"/>
+		</fileset>
+    </path>
+
+    <target name="init">
+		<antcall target="common-build.init"/>
+		<!-- check for dependency artefacts -->
+		<available file="${jpa-api.jar}" type="file" property="jpa-api.jar.available"/>
+		<available file="${commons-annotations.jar}" type="file" property="commons-annotations.jar.available"/>
+		<available file="${annotations.jar}" type="file" property="annotations.jar.available"/>
+        <available file="${validator.jar}" type="file" property="validator.jar.available"/>
+        <mkdir dir="${lib.dir}/test"/>
+    </target>
+
+	<target name="get.jpa-api" depends="init" unless="jpa-api.jar.available">
+		<ant inheritall="false" dir="${basedir}/../jpa-api" target="clean"/>
+		<ant inheritall="false" dir="${basedir}/../jpa-api" target="jar"/>
+	</target>
+
+	<target name="get.commons-annotations" depends="init" unless="commons-annotations.jar.available">
+		<ant inheritall="false" dir="${basedir}/../commons-annotations" target="clean"/>
+		<ant inheritall="false" dir="${basedir}/../commons-annotations" target="jar"/>
+	</target>
+
+	<target name="get.annotations" depends="init" unless="annotations.jar.available">
+		<ant inheritall="false" dir="${basedir}/../annotations" target="clean"/>
+		<ant inheritall="false" dir="${basedir}/../annotations" target="jar"/>
+	</target>
+
+    <target name="get.validator" depends="init" unless="validator.jar.available">
+		<ant inheritall="false" dir="${basedir}/../validator" target="clean"/>
+		<ant inheritall="false" dir="${basedir}/../validator" target="jar"/>
+	</target>
+
+    <target name="compile" depends="init,get.jpa-api,get.commons-annotations,get.annotations,get.validator" description="Compile the Java source code">
+        <available
+                classname="org.eclipse.core.launcher.Main"
+                property="build.compiler"
+                value="org.eclipse.jdt.core.JDTCompilerAdapter"
+                classpath="${java.class.path}"/>
+        <javac
+                srcdir="${src.dir}"
+                destdir="${classes.dir}"
+                classpathref="lib.class.path"
+                debug="${javac.debug}"
+                optimize="${javac.optimize}"
+                nowarn="on"
+				source="${javac.source}"
+                target="${javac.target}"
+                >
+        </javac>
+    </target>
+
+    <target name="packjar">
+        <property name="extension" value="jar"/>
+		<property name="packagename" value="${jarname}"/>
+		<!-- property name="jarname"/ -->
+        <mkdir dir="${build.testresources.dir}"/>
+        <jar destfile="${build.testresources.dir}/${jarname}.${extension}">
+            <!-- fileset dir="${build.temp.dir}"/ -->
+            <fileset dir="${classes.dir}">
+                <include name="**/test/pack/${packagename}/**.*"/>
+            </fileset>
+            <fileset dir="${testresources.dir}/${jarname}">
+                <include name="**/*.*"/>
+            </fileset>
+        </jar>
+        <delete dir="${build.temp.dir}"/>
+    </target>
+
+    <target name="packexploded">
+        <property name="extension" value="jar"/>
+        <!-- property name="jarname"/ -->
+        <mkdir dir="${build.testresources.dir}/${jarname}.${extension}"/>
+        <copy todir="${build.testresources.dir}/${jarname}.${extension}">
+            <!-- fileset dir="${build.temp.dir}"/ -->
+            <fileset dir="${classes.dir}">
+                <include name="**/test/pack/${jarname}/**.*"/>
+            </fileset>
+            <fileset dir="${testresources.dir}/${jarname}">
+                <include name="**/*.*"/>
+            </fileset>
+        </copy>
+        <delete dir="${build.temp.dir}"/>
+    </target>
+
+    <target name="test-resources" description="Prepare all needed jars and pars">
+        <antcall target="packjar" inheritall="true">
+            <param name="extension" value="par"/>
+            <param name="jarname" value="defaultpar"/>
+        </antcall>
+		<antcall target="packjar" inheritall="true">
+            <param name="extension" value="par"/>
+            <param name="jarname" value="space par"/>
+			<param name="packagename" value="spacepar"/>
+		</antcall>
+		<antcall target="packjar" inheritall="true">
+            <param name="extension" value="par"/>
+            <param name="jarname" value="explicitpar"/>
+        </antcall>
+        <antcall target="packjar" inheritall="true">
+            <param name="extension" value="par"/>
+            <param name="jarname" value="excludehbmpar"/>
+        </antcall>
+        <antcall target="packjar" inheritall="true">
+            <param name="extension" value="jar"/>
+            <param name="jarname" value="externaljar"/>
+        </antcall>
+        <antcall target="packjar" inheritall="true">
+            <param name="extension" value="par"/>
+            <param name="jarname" value="cfgxmlpar"/>
+        </antcall>
+		<antcall target="packjar" inheritall="true">
+            <param name="extension" value="jar"/>
+            <param name="jarname" value="overridenpar"/>
+        </antcall>
+
+		<antcall target="packexploded" inheritall="true">
+            <param name="extension" value="par"/>
+            <param name="jarname" value="explodedpar"/>
+        </antcall>
+    </target>
+
+    <target name="compiletest" depends="compile" description="Compile the tests">
+        <available
+                classname="org.eclipse.core.launcher.Main"
+                property="build.compiler"
+                value="org.eclipse.jdt.core.JDTCompilerAdapter"
+                classpath="${java.class.path}"/>
+        <javac
+                srcdir="${test.dir}"
+                destdir="${classes.dir}"
+                debug="${javac.debug}"
+                optimize="${javac.optimize}"
+                nowarn="on"
+				source="${javac.source}"
+                target="${javac.target}">
+            <classpath>
+                <path refid="lib.class.path"/>
+            </classpath>
+        </javac>
+    </target>
+
+    <target name="junit" depends="compiletest,test-resources">
+        <mkdir dir="test_output"/>
+        <mkdir dir="${classes.dir}/META-INF/services"/>
+        <copy todir="${classes.dir}">
+            <fileset dir="${resources.dir}">
+                <include name="**/*.*"/>
+            </fileset>
+        </copy>
+        <junit fork="once" printsummary="yes" haltonfailure="yes">
+            <classpath>
+                <fileset dir="${jdbc.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.zip"/>
+                </fileset>
+                <dirset dir="${build.testresources.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.par"/>
+                </dirset>
+
+                <fileset dir="${build.testresources.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.par"/>
+                </fileset>
+                <path refid="lib.class.path"/>
+                <!-- pathelement path="${classes.dir}"/ -->
+                <dirset dir="${classes.dir}">
+                    <exclude name="**/pack/**.*"/>
+                </dirset>
+
+                <!-- pathelement path="build/test.par"/ -->
+                <pathelement path="${src.dir}"/>
+                <!-- pick up properties from here -->
+                <pathelement path="${test.dir}"/>
+                <!-- pick up mappings from here -->
+            </classpath>
+            <formatter type="plain"/>
+            <formatter type="xml"/>
+            <batchtest fork="yes" todir="test_output" haltonfailure="no">
+                <fileset dir="${classes.dir}">
+                    <include name="**/*Test.class"/>
+                </fileset>
+            </batchtest>
+        </junit>
+    </target>
+
+    <!-- Run a single unit test. -->
+    <target name="junitsingle" depends="compiletest"
+            description="Run a single test suite (requires testname and jdbc.driver properties)">
+        <mkdir dir="test_output"/>
+        <junit printsummary="yes" fork="yes" haltonfailure="yes">
+            <classpath>
+                <fileset dir="${jdbc.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.zip"/>
+                </fileset>
+                <path refid="lib.class.path"/>
+                <pathelement path="build/test.par"/>
+                <pathelement path="target/hibernate-entitymanager/hibernate-entitymanager.jar"/>
+                <pathelement path="${src.dir}"/>
+                <!-- pick up properties from here -->
+                <pathelement path="${test.dir}"/>
+                <!-- pick up mappings from here -->
+            </classpath>
+            <formatter type="plain"/>
+            <formatter type="xml"/>
+            <test fork="yes" todir="test_output" haltonfailure="no" name="${testname}"/>
+        </junit>
+    </target>
+
+    <target name="jar" depends="compile" description="Build the distribution .jar file">
+        <mkdir dir="${classes.dir}/META-INF/services"/>
+        <copy todir="${classes.dir}">
+            <fileset dir="${resources.dir}">
+                <include name="**/*.*"/>
+            </fileset>
+        </copy>
+        <manifest file="${classes.dir}/META-INF/MANIFEST.MF">
+            <attribute name="Product" value="${Name}"/>
+            <attribute name="Version" value="${version}"/>
+        </manifest>
+        <antcall target="common-build.jar"/>
+    </target>
+
+    <!-- target name="javadoc" description="Compile the Javadoc API documentation to dist dir">
+			<echo>Skipping java doc since ant's javadoc task cannot handle an alternative javadoc</echo>        	
+     </target -->
+	 
+	 <target name="jpa-javadoc" if="jpa-present">
+		 <mkdir dir="${jpa-javadoc.dir}"/>
+		 <ant dir="../jpa-api" target="javadoc" inheritAll="false"/>
+		 <copy todir="${jpa-javadoc.dir}">
+		     <fileset dir="${basedir}/../jpa-api/build/api">
+			     <include name="**/*.*"/>
+			 </fileset>
+		 </copy>
+	</target>
+
+    <!-- Some of this can probably be moved to common-build... -->
+    <target name="dist" depends="jar,javadoc,jpa-javadoc,copysource,copytest,copylib,extras" description="Build everything">
+
+        <ant inheritall="false" dir="${basedir}/doc/reference"/>
+        <copy todir="${dist.dir}/doc/reference" failonerror="false">
+            <fileset dir="${basedir}/doc/reference/build">
+                <include name="**/*.*"/>
+            </fileset>
+        </copy>
+
+        <copy todir="${dist.dir}/resources" failonerror="false">
+            <fileset dir="${resources.dir}">
+                <include name="**/*.*"/>
+            </fileset>
+        </copy>
+        <copy todir="${dist.dir}/test-resources" failonerror="false">
+            <fileset dir="${testresources.dir}">
+                <include name="**/*.*"/>
+            </fileset>
+        </copy>
+        <copy todir="${dist.dir}" failonerror="false">
+            <fileset dir="${common.dir}">
+                <include name="common-build.xml"/>
+            </fileset>
+        </copy>
+
+        <!-- copy dependencies -->
+        <copy todir="${dist.lib.dir}" failonerror="false">
+			<fileset file="${jpa-api.jar}"/>
+            <fileset file="${commons-annotations.jar}"/>
+            <fileset file="${annotations.jar}"/>
+            <fileset file="${validator.jar}"/>
+        </copy>
+        <mkdir dir="${dist.lib.dir}/test"/>
+
+        <copy file="${basedir}/build.properties.dist" tofile="${dist.dir}/build.properties" failonerror="false">
+        </copy>
+        <antcall target="common-build.dist"/>
+    </target>
+
+    <target name="zip-dist" description="zip the dist">
+        <zip zipfile="${dist.dir}-${version}.zip">
+            <zipfileset prefix="${name}-${version}" dir="${dist.dir}"/>
+        </zip>
+        <tar compression="gzip" tarfile="${dist.dir}-${version}.tar.gz">
+            <tarfileset prefix="${name}-${version}" dir="${dist.dir}"/>
+        </tar>
+    </target>
+
+    <target name="profile" depends="compiletest">
+        <java classname="org.hibernate.ejb.test.Profile" fork="true">
+            <jvmarg value="-XrunjbossInspector:c:\profiler\data,include=org.hibernate.ejb,ignore=*,wakeupOnStartup=true"/>
+            <classpath>
+                <fileset dir="${jdbc.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.zip"/>
+                </fileset>
+                <dirset dir="${build.testresources.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.par"/>
+                </dirset>
+
+                <fileset dir="${build.testresources.dir}">
+                    <include name="**/*.jar"/>
+                    <include name="**/*.par"/>
+                </fileset>
+                <path refid="lib.class.path"/>
+                <pathelement path="${classes.dir}"/>
+                <!-- pathelement path="build/test.par"/ -->
+                <pathelement path="${src.dir}"/>
+                <!-- pick up properties from here -->
+                <pathelement path="${test.dir}"/>
+                <!-- pick up mappings from here -->
+            </classpath>
+        </java>
+    </target>
+
+
+</project>




More information about the hibernate-commits mailing list