You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by hi...@apache.org on 2006/06/20 16:39:14 UTC

svn commit: r415665 - in /incubator/harmony/enhanced/classlib/trunk/modules/jndi: build.xml make/build.xml make/common/ make/hyproperties.xml

Author: hindessm
Date: Tue Jun 20 07:39:14 2006
New Revision: 415665

URL: http://svn.apache.org/viewvc?rev=415665&view=rev
Log:
Move jndi build.xml up one level.

Added:
    incubator/harmony/enhanced/classlib/trunk/modules/jndi/build.xml
    incubator/harmony/enhanced/classlib/trunk/modules/jndi/make/hyproperties.xml
      - copied unchanged from r415565, incubator/harmony/enhanced/classlib/trunk/modules/jndi/make/common/hyproperties.xml
Removed:
    incubator/harmony/enhanced/classlib/trunk/modules/jndi/make/build.xml
    incubator/harmony/enhanced/classlib/trunk/modules/jndi/make/common/

Added: incubator/harmony/enhanced/classlib/trunk/modules/jndi/build.xml
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/jndi/build.xml?rev=415665&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/jndi/build.xml (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/jndi/build.xml Tue Jun 20 07:39:14 2006
@@ -0,0 +1,188 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Copyright 2006 The Apache Software Foundation or its
+    licensors, as applicable.
+  
+    Licensed 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="JNDI Build" default="build" basedir=".">
+    <description>Build for JNDI component</description>
+
+    <!-- import common properties -->
+    <import file="${basedir}/../../make/properties.xml" />
+
+    <!-- set global properties for this build. -->
+    <xmlproperty file="make/hyproperties.xml" semanticAttributes="true" />
+
+    <!-- Set build.compiler to "org.eclipse.jdt.core.JDTCompilerAdapter" to
+	     use the Eclipse Java compiler. -->
+    <property name="build.compiler" value="modern" />
+
+    <target name="build" depends="compile.java, build.jar" />
+
+    <target name="test" depends="build, compile.tests, run.tests" />
+
+    <target name="clean">
+        <delete failonerror="false">
+            <fileset dir="${hy.build}"
+                     includesfile="${hy.jndi}/make/patternset.txt" />
+            <fileset dir="${hy.jndi.bin.test}" />
+        </delete>
+    </target>
+
+    <target name="compile.java">
+        <echo message="Compiling JNDI classes" />
+
+        <mkdir dir="${hy.build}" />
+
+        <javac sourcepath=""
+               srcdir="${hy.jndi.src.main.java}"
+               destdir="${hy.build}"
+               source="${hy.javac.source}"
+               target="${hy.javac.target}"
+               debug="${hy.javac.debug}">
+
+            <bootclasspath>
+                <fileset dir="${hy.jdk}/jre/lib/boot">
+                    <include name="**/*.jar" />
+                </fileset>
+            </bootclasspath>
+        </javac>
+    </target>
+
+    <target name="build.jar">
+        <jar destfile="${hy.jdk}/jre/lib/boot/jndi.jar"
+             manifest="${hy.jndi}/META-INF/MANIFEST.MF">
+            <fileset dir="${hy.build}"
+                     includesfile="${hy.jndi}/make/patternset.txt" />
+        </jar>
+    </target>
+
+    <target name="compile.tests" depends="copy.test.resources" >
+        <echo message="Compiling JNDI tests" />
+
+        <mkdir dir="${hy.jndi.bin.test}" />
+
+        <javac srcdir="${hy.jndi.src.test.java}"
+            destdir="${hy.jndi.bin.test}"
+            sourcepath=""
+            source="${hy.javac.source}"
+            target="${hy.javac.target}"
+            debug="${hy.javac.debug}">
+
+            <bootclasspath>
+                <fileset dir="${hy.jdk}/jre/lib/boot">
+                    <include name="**/*.jar" />
+                </fileset>
+            </bootclasspath>
+            <classpath location="../../build/tests" />
+        </javac>
+    </target>
+
+    <target name="run.tests">
+
+        <mkdir dir="${hy.tests.reports}" />
+
+        <property name="test.jre.home" value="${hy.jdk}/jre" />
+
+        <junit fork="yes"
+               forkmode="perBatch"
+               printsummary="withOutAndErr"
+               errorproperty="test.errors"
+               failureproperty="test.failures"
+               showoutput="on"
+               dir="${hy.jndi.bin.test}"
+               jvm="${test.jre.home}/bin/java">
+
+            <jvmarg value="-showversion"/>
+
+            <env key="JAVA_HOME" value="${test.jre.home}"/>
+
+            <classpath>
+                <pathelement path="${hy.jndi.bin.test}"/>
+            </classpath>
+            <classpath location="../../build/tests" />
+
+            <formatter type="xml" />
+
+            <test name="${test.case}" todir="${hy.tests.reports}"
+                 if="test.case" />
+
+        	
+            <batchtest todir="${hy.tests.reports}" haltonfailure="no"
+                unless="test.case">
+
+                <fileset dir="${hy.jndi.src.test.java}">
+                    <include name="**/*Test.java"/>
+                        <exclude name="org/apache/harmony/jndi/provider/dns/DNSContextTest.java" />                	
+
+                	<!--  These tests run in a separate jvm below -->
+                	<exclude name="org/apache/harmony/jndi/tests/javax/naming/spi/NamingManagerBuilderTest.java" />
+                    <exclude name="org/apache/harmony/jndi/tests/javax/naming/spi/NamingManagerTest.java" />
+                	<exclude name="org/apache/harmony/jndi/tests/javax/naming/spi/DirectoryManagerTest.java" />
+                </fileset>
+            </batchtest>
+        	
+            <batchtest todir="${hy.tests.reports}" haltonfailure="no"
+        	       unless="test.case">
+        	
+        	<fileset dir="${hy.jndi.src.test.java}">
+        	    <include name="org/apache/harmony/jndi/tests/javax/naming/spi/NamingManagerTest.java" />
+        	</fileset>
+            </batchtest>
+        	
+            <batchtest todir="${hy.tests.reports}" haltonfailure="no"
+        	       unless="test.case">
+        	
+        	<fileset dir="${hy.jndi.src.test.java}">
+        	    <include name="org/apache/harmony/jndi/tests/javax/naming/spi/NamingManagerBuilderTest.java" />
+        	</fileset>
+            </batchtest>        	
+        	
+            <batchtest todir="${hy.tests.reports}" haltonfailure="no"
+        	       unless="test.case">
+        	
+        	<fileset dir="${hy.jndi.src.test.java}">
+        	    <include name="org/apache/harmony/jndi/tests/javax/naming/spi/DirectoryManagerTest.java" />
+        	</fileset>
+            </batchtest>        	
+            
+        </junit>
+        <antcall target="touch-failures-file" />
+        <antcall target="touch-errors-file" />
+    </target>
+
+    <target name="touch-failures-file" if="test.failures">
+        <echo file="${hy.tests.reports}/test.failures"
+            append="true" >jndi
+</echo>
+    </target>
+
+    <target name="touch-errors-file" if="test.errors">
+        <echo file="${hy.tests.reports}/test.errors"
+            append="true" >jndi
+</echo>
+    </target>
+
+    <target name="copy.test.resources">
+        <mkdir dir="${hy.jndi.bin.test}" />
+        <copy todir="${hy.jndi.bin.test}" includeemptydirs="false">
+            <fileset dir="${hy.jndi.src.test.resources}">
+                <exclude name="**/*.java" />
+                <exclude name="**/*.zip" />
+            </fileset>
+        </copy>
+    </target>
+
+</project>