harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ge...@apache.org
Subject svn commit: r369656 - in /incubator/harmony/enhanced/classlib/trunk/modules/security2/make: build.xml download.xml
Date Tue, 17 Jan 2006 03:36:53 GMT
Author: geirm
Date: Mon Jan 16 19:36:49 2006
New Revision: 369656

URL: http://svn.apache.org/viewcvs?rev=369656&view=rev
Log:
change build to not be dependant on the users classpath, a
source of certain misery and pain.

Also, make the thing automatically download the deps and 
use them.


Added:
    incubator/harmony/enhanced/classlib/trunk/modules/security2/make/download.xml
Modified:
    incubator/harmony/enhanced/classlib/trunk/modules/security2/make/build.xml

Modified: incubator/harmony/enhanced/classlib/trunk/modules/security2/make/build.xml
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/security2/make/build.xml?rev=369656&r1=369655&r2=369656&view=diff
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/security2/make/build.xml (original)
+++ incubator/harmony/enhanced/classlib/trunk/modules/security2/make/build.xml Mon Jan 16
19:36:49 2006
@@ -15,12 +15,8 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
-<!-- 
-Author: Natalya S. Naumova, Alexei Y. Zakharov, Igor A. Pyankov, Vladimir N. Molotkov
-Version: $Revision$
--->
 
-<project name="CLBuild" default="dist" basedir="..">
+<project name="HarmonySecurityBuild" default="dist" basedir="..">
 
     <description> Build for Security stuff </description>
 
@@ -188,7 +184,6 @@
     </target>
 
 
-
     <!-- SECURITY PACKAGES SETS -->
 
     <patternset id="crypto">
@@ -340,6 +335,21 @@
 
 
     <target name="tests.compile">
+    	
+    	<!-- download the jars we need for testing and create a path -->
+    	
+    	<ant antfile="make/download.xml" target="test-download" />
+    		
+        <mkdir dir="${build.path}/tests_report" />
+
+    	<path id="sec.test.path">
+    		<fileset dir="${build.path}/lib">
+		        <include name="**/*.jar"/>
+		      </fileset>
+	     </path>
+    		
+    	<property name="test.deps.path" refid="sec.test.path" />
+
         <echo message="Compiling Security tests from ${src.tst.common}/unit, ${src.tst.common.ps}/unit"
/>
     
         <mkdir dir="${build.path}/tests" />
@@ -347,7 +357,7 @@
         <javac srcdir="${src.tst.common}/unit;${src.tst.common.ps}/unit"
                destdir="${build.path}/tests"
                sourcepath=""
-               classpath="${env.CLASSPATH};${build.path}/tests"
+               classpath="${env.CLASSPATH};${build.path}/tests;${test.deps.path}"
                bootclasspath="${build.jars.path}/security.jar;${build.jars.path}/crypto.jar;${build.jars.path}/x_net.jar;${java.home}/lib/rt.jar"
                source="${source.ver}"
                debug="${java.debug.option}"
@@ -366,8 +376,9 @@
     </target>
 
     <target name="run">
-        <mkdir dir="${build.path}/tests_report" />
-        
+    	
+    	<!-- run the tests -->
+    	
         <junit fork="yes"
             forkmode="perTest"
             printsummary="withOutAndErr"
@@ -375,9 +386,9 @@
             showoutput="on"
             dir="${basedir}"
             jvm="${env.JAVA_HOME}/bin/java">
-
-            <jvmarg value="-Xbootclasspath/p:${build.path}/classes/security_alt.jar${path.separator}${build.jars.path}/crypto.jar${path.separator}${build.jars.path}/x_net.jar"/>
-            <jvmarg value="-Xbootclasspath/a:${build.path}/tests${path.separator}${env.CLASSPATH}"/>
+ 
+        	<jvmarg value="-Xbootclasspath/p:${build.path}/classes/security_alt.jar${path.separator}${build.jars.path}/crypto.jar${path.separator}${build.jars.path}/x_net.jar"/>
+            <jvmarg value="-Xbootclasspath/a:${build.path}/tests${path.separator}${test.deps.path}"/>
             <jvmarg value="-Dreference.output=${src.tst.common}/unit" />
             <jvmarg value="-Dunit.test.root=${src.tst.common}/unit"/>
             <jvmarg value="-Djava.security.properties==${build.lib.path}/security/java.security"/>

Added: incubator/harmony/enhanced/classlib/trunk/modules/security2/make/download.xml
URL: http://svn.apache.org/viewcvs/incubator/harmony/enhanced/classlib/trunk/modules/security2/make/download.xml?rev=369656&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/security2/make/download.xml (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/security2/make/download.xml Mon Jan
16 19:36:49 2006
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
+<!--
+    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="harmony-classlib-security" basedir="..">
+
+	<target name="test-download" description="Download all deps for testing">
+		<mkdir dir="${build.path}/lib" />
+		<antcall target="junit" />
+		<antcall target="bcprov" />
+	</target>
+
+	<target name="http-download" unless="skip.jar.loading">
+		<get src="http://www.ibiblio.org/maven/${projectname}/jars/${jarname}-${jarversion}.jar"
+           dest="${build.path}/lib/${jarname}-${jarversion}.jar"
+           usetimestamp="true"
+           verbose="false"
+           ignoreerrors="false" />
+	</target>
+
+	<target name="junit">
+		<property name="projectname" value="junit" />
+		<property name="jarname" value="junit" />
+		<property name="jarversion" value="3.8.1" />
+		<antcall target="http-download"/>
+	</target>
+
+	<target name="bcprov">
+		<property name="projectname" value="bouncycastle" />
+ 		<property name="jarname" value="bcprov" />
+ 		<property name="jarversion" value="jdk14-124" />
+ 		<antcall target="http-download"/>
+	</target>
+
+</project>
\ No newline at end of file



Mime
View raw message