Author: ekoneil
Date: Sat Mar 12 13:52:52 2005
New Revision: 157286

URL: http://svn.apache.org/viewcvs?view=rev&rev=157286
Log:
Rename buildWebappCore.xml to beehive-tools.xml.  This adds a .properties file 
for the distribution that defines various resources needed to build a webapp 
including the JSP and Servlet APIs.

Removes some unused shell scripts and an old beehive.properties file that 
should have been deleted a while ago.

The NetUI-enabled webapps in the distribution now are structured as:

  WEB-INF/src/
              build.xml
              build.properties

where build.properties defines beehive.home.  Then, the build.xml file simply 
imports the beehive-imports.xml file to obtain the <path>s defined there and 
beehive-tools.xml to define the tools used to build JPFs, controls, and XSDs.  

BB: self
DRT: Beehive pass
BVT: NetUI pass
Tests: distribution tests pass


Added:
    incubator/beehive/trunk/ant/beehive-tools.xml
      - copied, changed from r157131, 
incubator/beehive/trunk/ant/buildWebappCore.xml
    incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build.properties   
(with props)
    incubator/beehive/trunk/test/dist-test/ant/testdist-buildWebapp.xml   (with 
props)
    incubator/beehive/trunk/user/netui-blank/
    incubator/beehive/trunk/user/netui-blank/build.properties   (with props)
    incubator/beehive/trunk/user/netui-blank/build.xml   (with props)
Removed:
    incubator/beehive/trunk/ant/buildWebappCore.xml
    incubator/beehive/trunk/user/beehive.properties
    incubator/beehive/trunk/user/beehiveUser.cmd
    incubator/beehive/trunk/user/beehiveUser.sh
    incubator/beehive/trunk/user/buildWebapp.xml
Modified:
    incubator/beehive/trunk/ant/buildWebapp.xml
    incubator/beehive/trunk/build.xml
    incubator/beehive/trunk/distribution.xml
    incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build-dist.xml
    incubator/beehive/trunk/test/dist-test/ant/build.xml
    incubator/beehive/trunk/test/dist-test/ant/test-imports.xml
    incubator/beehive/trunk/test/dist-test/build.xml
    incubator/beehive/trunk/user/beehive-imports.xml

Copied: incubator/beehive/trunk/ant/beehive-tools.xml (from r157131, 
incubator/beehive/trunk/ant/buildWebappCore.xml)
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/ant/beehive-tools.xml?view=diff&rev=157286&p1=incubator/beehive/trunk/ant/buildWebappCore.xml&r1=157131&p2=incubator/beehive/trunk/ant/beehive-tools.xml&r2=157286
==============================================================================
--- incubator/beehive/trunk/ant/buildWebappCore.xml (original)
+++ incubator/beehive/trunk/ant/beehive-tools.xml Sat Mar 12 13:52:52 2005
@@ -1,50 +1,45 @@
 <?xml version="1.0"?>
+<!--
+   Copyright 2004 The Apache Software Foundation.
 
-<!-- ================================================================ -->
-<!--                                                                  -->
-<!--                                                                  -->
-<!--                                                                  -->
-<!--                                                                  -->
-<!--                                                                  -->
-<!-- ================================================================ -->
-<project name="Beehive/CoreWebappBuild" default="usage">
-
-    <property name="tmp.sourcegen.dir" value=".tmpbeansrc"/>
-
-    <!-- required paths:
-        appserver.build.classpath
-        velocity.dependency.path
-        controls.dependency.path
-        netui-compiler.dependency.path
-     -->
-    <path id="controls.build.classpath">
-        <path refid="webapp.build.classpath"/>
-        <path refid="appserver.build.classpath"/>
-        <path refid="velocity.dependency.path"/>
-    </path>
+   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.
+  
+   $Header:$
+ -->
+
+<!--
+  This Ant build file contains <macrodef>s that are used to build
+  Beehive-related source artifacts.
+-->
+<project name="Beehive/Tools" default="usage">
 
-    <path id="beehive-apt.dependency.path">
+    <path id="apt.task.classpath">
         <path refid="controls.dependency.path"/>
-        <path refid="netui-compiler.dependency.path"/>
-    </path>
-
-    <path id="pageflow.build.classpath">
-        <path refid="controls.build.classpath"/>
-        <path refid="beehive-apt.dependency.path"/>
+        <path refid="velocity.dependency.path"/>
     </path>
 
     <macrodef name="build-schemas">
         <attribute name="sourceDir"/>
         <attribute name="destDir"/>
         <sequential>
-        <taskdef name="xmlbeanbuild" 
-                 classname="org.apache.xmlbeans.impl.tool.XMLBean" 
-                 classpathref="xbean.dependency.path"/>
-
-        <xmlbeanbuild classpathref="xbean.dependency.path"
-                      schema="@{sourceDir}"
-                      classgendir="@{destDir}"
-                      failonerror="true"/>
+            <taskdef name="xmlbeanbuild" 
+                     classname="org.apache.xmlbeans.impl.tool.XMLBean" 
+                     classpathref="xbean.dependency.path"/>
+
+            <xmlbeanbuild classpathref="xbean.dependency.path"
+                          schema="@{sourceDir}"
+                          classgendir="@{destDir}"
+                          failonerror="true"/>
         </sequential>
     </macrodef>
 
@@ -52,20 +47,29 @@
         <attribute name="sourceDir"/>
         <attribute name="destDir"/>
         <attribute name="tmpDir"/>
+        <attribute name="classpathRef"/>
         <sequential>
+            <taskdef name="apt" 
+                     
classname="org.apache.beehive.controls.runtime.generator.AptTask" 
+                     classpathref="apt.task.classpath"
+                     onerror="fail"/>
+
+            <!-- 
+                 since Velocity is required at build time for controls, it 
needs to be
+                 explicitly added  here via the velocity.dependency.path
+              -->
+            <path id="_controls.build.classpath">
+                <path refid="@{classpathRef}"/>
+                <path refid="velocity.dependency.path"/>
+            </path>
 
-        <taskdef name="apt" 
-                 
classname="org.apache.beehive.controls.runtime.generator.AptTask" 
-                 classpathref="beehive-apt.dependency.path"
-                 onerror="report"/>
-
-        <apt srcdir="@{sourceDir}"
-             destdir="@{destDir}"
-             gendir="@{tmpDir}"
-             classpathref="controls.build.classpath" 
-             compileByExtension="true" 
-             srcExtensions="*.java,*.jcx,*.jcs,*.jws" 
-             debug="true"/>
+            <apt srcdir="@{sourceDir}"
+                 destdir="@{destDir}"
+                 gendir="@{tmpDir}"
+                 classpathref="_controls.build.classpath"
+                 compileByExtension="true" 
+                 srcExtensions="*.java,*.jcx,*.jcs,*.jws" 
+                 debug="true"/>
         </sequential>
     </macrodef>
 
@@ -73,11 +77,27 @@
         <attribute name="sourceDir"/>
         <attribute name="destDir"/>
         <attribute name="tmpDir"/>
+        <attribute name="classpathRef"/>
         <sequential>
+            <taskdef name="apt" 
+                     
classname="org.apache.beehive.controls.runtime.generator.AptTask" 
+                     classpathref="apt.task.classpath"
+                     onerror="fail"/>
+
+            <!-- 
+                 since the annotation processor for JPFs isn't contained 
inside of the JPF runtime
+                 JAR, it needs to be explicitly added here via the 
netui-compiler.dependency.path
+              -->
+            <path id="_pageflow.build.classpath">
+                <path refid="@{classpathRef}"/>
+                <path refid="netui-compiler.dependency.path"/>
+                <path refid="velocity.dependency.path"/>
+            </path>
+
             <apt srcdir="@{sourceDir}" 
                  destdir="@{destDir}"
                  gendir="@{tmpDir}"
-                 classpathref="pageflow.build.classpath" 
+                 classpathref="_pageflow.build.classpath"
                  srcExtensions="*.jpf,*.jpfs,*.app,*.jsfb,*.java" 
                  debug="true"/>
         </sequential>

Modified: incubator/beehive/trunk/ant/buildWebapp.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/ant/buildWebapp.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/ant/buildWebapp.xml (original)
+++ incubator/beehive/trunk/ant/buildWebapp.xml Sat Mar 12 13:52:52 2005
@@ -6,7 +6,12 @@
     <property name="tmp.jpfgen.dir" value=".pageflow-struts-generated"/>
 
     <import file="../beehive-imports.xml"/>
-    <import file="buildWebappCore.xml"/>
+    <import file="beehive-tools.xml"/>
+
+    <!-- 
+         the ${servlet.runtime} file is imported in order to pickup 
+         the "appserver.build.classpath" referenced below
+      -->
     <import file="${servlet.runtime}-imports.xml"/>
 
     <target name="build">
@@ -14,7 +19,8 @@
         <fail unless="webapp.dir.available" message="Can't find the webapp 
directory ${webapp.dir}"/>
 
         <!-- this is the classpath to include when building webapp sources -->
-        <path id="webapp.build.classpath">
+        <path id="webapp.classpath">
+            <path refid="appserver.build.classpath"/>
             <pathelement location="${webapp.dir}/WEB-INF/classes"/>
             <fileset dir="${webapp.dir}/WEB-INF/lib">
                 <include name="*.jar"/>
@@ -31,25 +37,30 @@
         <mkdir dir="${webapp.dir}/WEB-INF/classes"/>
 
         <!-- compile XSDs -->
-        <build-schemas sourceDir="${webapp.dir}/WEB-INF/schemas" 
destDir="${webapp.dir}/WEB-INF/classes"/>
+        <echo>Building XML Schemas</echo>
+        <build-schemas sourceDir="${webapp.dir}/WEB-INF/schemas" 
+                       destDir="${webapp.dir}/WEB-INF/classes"/>
 
         <!-- compile controls -->
-        <build-controls sourceDir="${webapp.dir}/WEB-INF/src" 
destdir="${webapp.dir}/WEB-INF/classes" 
tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"/>
+        <echo>Building Controls</echo>
+        <build-controls sourceDir="${webapp.dir}/WEB-INF/src" 
+                        destdir="${webapp.dir}/WEB-INF/classes" 
+                        tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"
+                        classpathRef="webapp.classpath"/>
 
         <!-- compile JPFs -->
-        <build-pageflows sourceDir="${webapp.dir}" 
destdir="${webapp.dir}/WEB-INF/classes" 
tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"/>
+        <echo>Building Page Flows</echo>
+        <build-pageflows sourceDir="${webapp.dir}" 
+                         destdir="${webapp.dir}/WEB-INF/classes" 
+                         tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"
+                         classpathRef="webapp.classpath"/>
 
         <!-- copy resources -->
-       <echo>Copy all .properties files</echo>
+       <echo>Copying all .properties and .xml files to 
${webapp.dir}/WEB-INF/classes</echo>
         <copy todir="${webapp.dir}/WEB-INF/classes">
             <fileset dir="${webapp.dir}/WEB-INF/src" 
includes="**/*.properties"/>
-        </copy>
-
-       <echo>Copy all .xml files</echo>
-        <copy todir="${webapp.dir}/WEB-INF/classes/" failonerror="false">
             <fileset dir="${webapp.dir}/WEB-INF/src" includes="**/*.xml"/>
         </copy>
-
     </target>
 
     <target name="clean">

Modified: incubator/beehive/trunk/build.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/build.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/build.xml (original)
+++ incubator/beehive/trunk/build.xml Sat Mar 12 13:52:52 2005
@@ -186,10 +186,6 @@
         <ant antfile="distribution.xml" target="build.dist" 
inheritAll="false"/>
     </target>
 
-    <target name="test.dist">
-        <ant antfile="distribution.xml" target="test.dist" inheritAll="false"/>
-    </target>
-
     <target name="build.dist.archives">
         <ant antfile="distribution.xml" target="build.dist.archives" 
inheritAll="false"/>
     </target>

Modified: incubator/beehive/trunk/distribution.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/distribution.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/distribution.xml (original)
+++ incubator/beehive/trunk/distribution.xml Sat Mar 12 13:52:52 2005
@@ -1,7 +1,18 @@
 <?xml version="1.0"?>
 
 <!-- 
-    Beehive documentation build file.
+    Beehive distribution build file.
+
+    This build file contains the logic associated with creating Beehive 
distributions.  
+A distribution may take one of the following forms:
+
+  - full distribution (samples + runtime)
+  - library distribution (runtime)
+  - documentation distribution (doc)
+  - source distribution (source code)
+
+This file also contains targets for obtaining system controls from 
ControlHaus.  These
+remote repositories are pulled from svn.controlhaus.org onto the local disk 
and built.
 -->
 <project name="Beehive/Distribution" default="usage" basedir=".">
 
@@ -35,109 +46,102 @@
 
     <target name="build.system.controls" description="gets controls from 
controlhaus">
         <!-- this pulls down the most generally useful controls from 
-            controlhaus.org, and builds them into the distribution --> 
+             controlhaus.org, and builds them into the distribution --> 
 
-    <!-- ============================================= -->
-    <!--                                               -->
-    <!-- EJB Control                                   -->
-    <!--                                               -->
-    <!-- ============================================= -->
-       <available property="ejb.control.exists" 
file="controlhaus/ejb/trunk/build.xml"/>
-       <antcall target="ejb.svn.update"/>
-       <antcall target="ejb.svn.checkout"/>
-    <antcall target="ejb.svn.revision.label"/>
-
-       <ant dir="controlhaus/ejb/trunk" target="clean" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-        </ant>             
-       <ant dir="controlhaus/ejb/trunk" target="build" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
+        <!-- ============================================= -->
+        <!-- EJB Control                                   -->
+        <!-- ============================================= -->
+        <available property="ejb.control.exists" 
file="controlhaus/ejb/trunk/build.xml"/>
+        <antcall target="ejb.svn.update"/>
+        <antcall target="ejb.svn.checkout"/>
+        <antcall target="ejb.svn.revision.label"/>
+
+        <ant dir="controlhaus/ejb/trunk" target="clean" inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
+        </ant>                    
+        <ant dir="controlhaus/ejb/trunk" target="build" inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
         </ant>   
-       
-       <copy file="controlhaus/ejb/trunk/build/ejb-control.jar" 
todir="${dist.dir}/lib/controls"/> 
-       
-    <!-- ============================================= -->
-    <!--                                               -->
-    <!-- JDBC Control                                  -->
-    <!--                                               -->
-    <!-- ============================================= -->
-       <available property="jdbc.control.exists" 
file="controlhaus/jdbc/trunk/build.xml"/>
-       <antcall target="jdbc.svn.update"/>
-       <antcall target="jdbc.svn.checkout"/>
-    <antcall target="jdbc.svn.revision.label"/>
-
-       <ant dir="controlhaus/jdbc/trunk" target="download-dependencies" 
inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-        </ant>             
-       <ant dir="controlhaus/jdbc/trunk" target="clean" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-        </ant>             
-       <ant dir="controlhaus/jdbc/trunk" target="build" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-        </ant>             
-
-       <copy file="controlhaus/jdbc/trunk/build/dist/jdbc-control.jar" 
todir="${dist.dir}/lib/controls"/> 
-
-    <!-- ============================================= -->
-       <!--                                               -->
-    <!-- JMS Control                                   -->
-    <!--                                               -->
-    <!-- ============================================= -->
-       <available property="jms.control.exists" 
file="controlhaus/jms/trunk/build.xml"/>
-       <antcall target="jms.svn.update"/>
-       <antcall target="jms.svn.checkout"/>
-    <antcall target="jms.svn.revision.label"/>
-
-       <ant dir="controlhaus/jms/trunk" target="clean" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-        </ant>             
-       <ant dir="controlhaus/jms/trunk" target="build" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
+        
+        <copy file="controlhaus/ejb/trunk/build/ejb-control.jar" 
todir="${dist.dir}/lib/controls"/> 
+        
+        <!-- ============================================= -->
+        <!-- JDBC Control                                  -->
+        <!-- ============================================= -->
+        <available property="jdbc.control.exists" 
file="controlhaus/jdbc/trunk/build.xml"/>
+        <antcall target="jdbc.svn.update"/>
+        <antcall target="jdbc.svn.checkout"/>
+        <antcall target="jdbc.svn.revision.label"/>
+
+        <ant dir="controlhaus/jdbc/trunk" target="download-dependencies" 
inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
+        </ant>                    
+        <ant dir="controlhaus/jdbc/trunk" target="clean" inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
+        </ant>                    
+        <ant dir="controlhaus/jdbc/trunk" target="build" inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
+        </ant>                    
+
+        <copy file="controlhaus/jdbc/trunk/build/dist/jdbc-control.jar" 
todir="${dist.dir}/lib/controls"/> 
+
+        <!-- ============================================= -->
+        <!-- JMS Control                                   -->
+        <!-- ============================================= -->
+        <available property="jms.control.exists" 
file="controlhaus/jms/trunk/build.xml"/>
+        <antcall target="jms.svn.update"/>
+        <antcall target="jms.svn.checkout"/>
+        <antcall target="jms.svn.revision.label"/>
+
+        <ant dir="controlhaus/jms/trunk" target="clean" inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
+        </ant>                    
+        <ant dir="controlhaus/jms/trunk" target="build" inheritAll="false">
+            <property name="beehive.home" value="${dist.dir}"/>
         </ant>   
 
-       <copy file="controlhaus/jms/trunk/build/jms-control.jar" 
todir="${dist.dir}/lib/controls"/> 
+        <copy file="controlhaus/jms/trunk/build/jms-control.jar" 
todir="${dist.dir}/lib/controls"/> 
 
-    <!-- ============================================= -->
-    <!--                                               -->
-    <!-- Webservice Control                            -->
-    <!--                                               -->
-    <!-- ============================================= -->
-       <available property="webservice.control.exists" 
file="controlhaus/webservice/trunk/build.xml"/>
-       <antcall target="webservice.svn.update"/>
-       <antcall target="webservice.svn.checkout"/>
-    <antcall target="webservice.svn.revision.label"/>
+        <!-- ============================================= -->
+        <!-- Webservice Control                            -->
+        <!-- ============================================= -->
+        <available property="webservice.control.exists" 
file="controlhaus/webservice/trunk/build.xml"/>
+        <antcall target="webservice.svn.update"/>
+        <antcall target="webservice.svn.checkout"/>
+        <antcall target="webservice.svn.revision.label"/>
       
-       <ant dir="controlhaus/webservice/trunk" target="clean" 
inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-       </ant>
-       <ant dir="controlhaus/webservice/trunk" target="jar" inheritAll="false">
-           <property name="beehive.home" value="${dist.dir}"/>
-       </ant>
-
-       <copy 
file="controlhaus/webservice/trunk/servicecontrol/build/jars/webservice-control.jar"
-           todir="${dist.dir}/lib/controls"/>        
-
-    <!-- Track the svn revs used for this distro build -->
-    <concat destfile="${dist.dir}/lib/controls/controlhaus.rev" 
fixlastline="true" eol="crlf">
-        <fileset dir="controlhaus">
-            <include name="**/svn.rev"/>
-        </fileset>
-    </concat>
- 
+        <ant dir="controlhaus/webservice/trunk" target="clean" 
inheritAll="false">
+              <property name="beehive.home" value="${dist.dir}"/>
+        </ant>
+        <ant dir="controlhaus/webservice/trunk" target="jar" 
inheritAll="false">
+              <property name="beehive.home" value="${dist.dir}"/>
+        </ant>
+
+        <copy 
file="controlhaus/webservice/trunk/servicecontrol/build/jars/webservice-control.jar"
+             todir="${dist.dir}/lib/controls"/>        
+
+        <!-- Track the svn revs used for this distro build -->
+        <concat destfile="${dist.dir}/lib/controls/controlhaus.rev" 
fixlastline="true" eol="crlf">
+            <fileset dir="controlhaus">
+                <include name="**/svn.rev"/>
+            </fileset>
+        </concat>
     </target>
 
     <!-- EJB Control svn targets -->
     <target name="ejb.svn.update" if="ejb.control.exists">
-       <exec executable="svn" dir="${beehive.home}/controlhaus/ejb/trunk">
-           <arg line="update"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/ejb/trunk">
+            <arg line="update"/>
         </exec>
     </target>
+
     <target name="ejb.svn.checkout" unless="ejb.control.exists">
         <mkdir dir="${beehive.home}/controlhaus/ejb"/>
-       <exec executable="svn" dir="${beehive.home}/controlhaus/ejb">
-           <arg line="checkout http://svn.controlhaus.org/ejb/trunk"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/ejb">
+            <arg line="checkout http://svn.controlhaus.org/ejb/trunk"/>
         </exec>
     </target>
+
     <target name="ejb.svn.revision.label">
         <exec executable="svnversion" 
dir="${beehive.home}/controlhaus/ejb/trunk"
               outputproperty="ejb.svn.revision">
@@ -148,16 +152,18 @@
 
     <!-- JDBC Control svn targets -->
     <target name="jdbc.svn.update" if="jdbc.exists">
-       <exec executable="svn" dir="${beehive.home}/controlhaus/jdbc/trunk">
-           <arg line="update"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/jdbc/trunk">
+            <arg line="update"/>
         </exec>
     </target>
+
     <target name="jdbc.svn.checkout" unless="jdbc.exists">
         <mkdir dir="${beehive.home}/controlhaus/jdbc"/>
-       <exec executable="svn" dir="${beehive.home}/controlhaus/jdbc">
-           <arg line="checkout http://svn.controlhaus.org/jdbc/trunk"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/jdbc">
+            <arg line="checkout http://svn.controlhaus.org/jdbc/trunk"/>
         </exec>
     </target>
+
     <target name="jdbc.svn.revision.label">
         <exec executable="svnversion" 
dir="${beehive.home}/controlhaus/jdbc/trunk"
               outputproperty="jdbc.svn.revision">
@@ -168,16 +174,18 @@
 
     <!-- JMS Control svn targets -->
     <target name="jms.svn.update" if="jms.exists">
-       <exec executable="svn" dir="${beehive.home}/controlhaus/jms/trunk">
-           <arg line="update"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/jms/trunk">
+            <arg line="update"/>
        </exec>
     </target>
+
     <target name="jms.svn.checkout" unless="jms.exists">
         <mkdir dir="${beehive.home}/controlhaus/jms"/>
-       <exec executable="svn" dir="${beehive.home}/controlhaus/jms">
-           <arg line="checkout http://svn.controlhaus.org/jms/trunk"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/jms">
+            <arg line="checkout http://svn.controlhaus.org/jms/trunk"/>
         </exec>
     </target>
+
     <target name="jms.svn.revision.label">
         <exec executable="svnversion" 
dir="${beehive.home}/controlhaus/jms/trunk"
               outputproperty="jms.svn.revision">
@@ -188,16 +196,18 @@
 
     <!-- Webservice Control svn targets -->
     <target name="webservice.svn.update" if="webservice.exists">
-       <exec executable="svn" 
dir="${beehive.home}/controlhaus/webservice/trunk">
-           <arg line="update"/>
+        <exec executable="svn" 
dir="${beehive.home}/controlhaus/webservice/trunk">
+            <arg line="update"/>
         </exec>
     </target>
+
     <target name="webservice.svn.checkout" unless="webservice.exists">
         <mkdir dir="${beehive.home}/controlhaus/webservice"/>
-       <exec executable="svn" dir="${beehive.home}/controlhaus/webservice">
-           <arg line="checkout http://svn.controlhaus.org/webservice/trunk"/>
+        <exec executable="svn" dir="${beehive.home}/controlhaus/webservice">
+            <arg line="checkout http://svn.controlhaus.org/webservice/trunk"/>
         </exec>
     </target>
+
     <target name="webservice.svn.revision.label">
         <exec executable="svnversion" 
dir="${beehive.home}/controlhaus/webservice/trunk"
               outputproperty="webservice.svn.revision">
@@ -206,8 +216,7 @@
         <echo message="ControlHaus WebService control svn revision 
#${webservice.svn.revision}" 
file="${beehive.home}/controlhaus/webservice/trunk/svn.rev"/>
     </target>
 
-
-    <!-- target for building libraries. required property: lib.dir -->
+    <!-- target for building libraries -->
     <target name="build.lib">
         <copy todir="${lib.dir}/common" failOnError="true">
             <fileset refid="commons-codec.fileset"/>
@@ -271,7 +280,7 @@
             <fileset dir="${beehive.home}/build">
                 <include name="svn.rev"/>
             </fileset>
-           <fileset file="docs/dist-docs/README.txt"/>
+            <fileset file="docs/dist-docs/README.txt"/>
         </copy>
     </target>
 
@@ -283,13 +292,10 @@
  
         <!-- copy the required Ant build files dist/ -->
         <copy todir="${dist.dir}/ant" failOnError="true">
+            <fileset file="ant/beehive-tools.xml"/>
             <fileset file="user/webappRuntimeCore.xml"/>
-            <fileset file="user/buildWebapp.xml"/>
-        </copy>
-        <copy todir="${dist.dir}" file="user/beehive-imports.xml"/>
-        <copy todir="${dist.dir}/ant" failOnError="true">
-            <fileset file="ant/buildWebappCore.xml"/>
         </copy>
+        <copy todir="${dist.dir}" file="user/beehive-imports.xml" 
failOnError="true"/>
 
         <copy todir="${dist.dir}" failOnError="true">
             <fileset dir="${beehive.home}">
@@ -299,7 +305,7 @@
             <fileset dir="${beehive.home}/build">
                 <include name="svn.rev"/>
             </fileset>
-           <fileset file="docs/dist-docs/README.txt"/>
+            <fileset file="docs/dist-docs/README.txt"/>
         </copy>
 
         <property name="webapp.name" value="netui-blank"/>
@@ -311,9 +317,15 @@
                 <exclude name="WEB-INF/lib/*.jar"/>
                 <exclude name="WEB-INF/*.tld"/>
                 <exclude name="WEB-INF/*.tldx"/>
+                <exclude name="WEB-INF/src/build.xml"/>
             </fileset>
         </copy>
 
+        <copy todir="${dist.dir}/samples/netui-blank/WEB-INF/src">
+            <fileset dir="${beehive.home}/user/netui-blank" includes="**"/>
+        </copy>
+
+        <!-- finally, move netui-blank from the staging directory into the 
distribution -->
         <copy todir="${dist.dir}/samples/netui-blank">
             <fileset dir="${dist.tmp.dir}/${webapp.name}"/>
         </copy>
@@ -422,6 +434,7 @@
                 <include name="dbControl.jar"/>
             </fileset>
         </copy>
+
         <ant 
                    dir="${dist.dir}/samples/controls-db" 
             antfile="build.xml" 
@@ -433,21 +446,20 @@
         <copy todir="${dist.dir}/samples" failOnError="true">
             <fileset file="samples/README.txt"/>
         </copy>
-
     </target>
 
     <target name="build.dist.docs" depends="docs" description="Builds 
documentation for a Beehive distribution">
         <mkdir dir="${dist.dir}"/>
         <!-- copy javadocs to dist -->
         
-       <copy todir="${dist.dir}/docs/apidocs" failOnError="true">
-           <fileset dir="controls/build/docs/apidocs"/>
+        <copy todir="${dist.dir}/docs/apidocs" failOnError="true">
+            <fileset dir="controls/build/docs/apidocs"/>
             <fileset dir="netui/build/docs/apidocs"/>
             <fileset dir="wsm/build/docs/apidocs"/>
         </copy>
-       
+        
         <copy todir="${dist.dir}/docs" failOnError="true">
-           <fileset dir="docs/forrest/build/site"/>
+            <fileset dir="docs/forrest/build/site"/>
         </copy>
 
         <copy todir="${dist.dir}/docs" failOnError="true">
@@ -458,9 +470,9 @@
             <fileset dir="${beehive.home}/build">
                 <include name="svn.rev"/>
             </fileset>
-           <fileset file="docs/dist-docs/README.txt"/>
+            <fileset file="docs/dist-docs/README.txt"/>
         </copy>
-    </target>          
+    </target>                
 
     <target name="build.dist.archives" depends="build.dist,build.dist.lib" 
description="Builds all Beehive distribution archives (.zip, .tar.gz, etc)">
         <fail unless="beehive.version" message="Could not build distribution 
archives; beehive.version property not specified!"/>
@@ -573,7 +585,7 @@
         <antcall target="build.dist.docs.tgz.non_windows"/>
 
         <delete dir="${tmpdocsdir}" />
-    </target>  
+    </target>        
 
     <target name="build.dist.docs.tgz.windows" if="isWindows">
         <exec executable="tar" dir="${dist.tmp.dir}">
@@ -622,31 +634,18 @@
     <target name="build.test.dist" description="Build and package the test 
module for testing distribution">
        <ant  dir="${beehive.home}/test/dist-test" 
              antfile="build.xml" 
-                 target="build.test.dist"
-                 inheritall="false"/>
+             target="build.test.dist"
+             inheritall="false"/>
     </target>
 
-    <!-- todo: this target needs to be removed -->
-    <target name="test.dist" description="Tests a Beehive distribution">
-        <echo>Testing distribution at ${dist.dir}</echo>
-        <property name="distroStdout.file" 
location="${beehive.home}/build/testDistro.output"/>
-
-        <exec executable="cmd" dir="${dist.dir}" newenvironment="true" 
os="Windows XP,Windows 2000" outputproperty="testDistro.output">
-            <arg line="/c ${beehive.home}/test/testDistro.cmd"/>
-        </exec>
-        <exec executable="sh" dir="${dist.dir}" newenvironment="true" 
os="Linux,SunOS,Solaris" outputproperty="testDistro.output">
-            <arg line="${beehive.home}/test/testDistro.sh"/>
-       </exec>
-        <fail message="${testDistro.output}">
-            <condition>
-               <not>
-                <contains string="${testDistro.output}" substring="BUILD 
SUCCESSFUL"/>
-               </not>
-            </condition>
-        </fail>
-        <echo message="${testDistro.output}"/>
-
-        <echo message="${testDistro.output}" file="${distroStdout.file}"/>
+    <target name="run.test.dist">
+<!--
+        <antcall target="build.dist"/>
+        <antcall target="build.test.dist"/>
+-->
+        <ant dir="${beehive.home}/test/dist-test" antfile="build.xml" 
target="run.test.dist" inheritall="false">
+            <property name="beehive.dist.dir" value="${dist.dir}"/> 
+            <property name="beehive.dist.name" value="${dist.name}"/> 
+       </ant>
     </target>
-
 </project>

Modified: incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build-dist.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build-dist.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build-dist.xml 
(original)
+++ incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build-dist.xml Sat 
Mar 12 13:52:52 2005
@@ -22,29 +22,84 @@
 -->
 <project name="Beehive/Samples/PetstoreWeb" default="usage" basedir="../..">
 
-    <import file="../../../../beehive-imports.xml"/>
+    <property environment="os"/>
+    <property file="${basedir}/WEB-INF/src/build.properties"/>
 
+    <import file="${beehive.home}/beehive-imports.xml"/>
+    <import file="${beehive.home}/ant/beehive-tools.xml"/>
+
+    <property name="webapp.dir" location="${basedir}"/>
     <property name="contextPath" value="petstoreWeb"/>
-    <property name="archive.dir" value="${basedir}/.."/>
 
-    <target name="build" description="Build the petstoreWeb webapp">
-        <build-webapp webappDir="${basedir}"/>
+    <property name="tmp.sourcegen.dir" value=".tmpbeansrc"/>
+    <property name="tmp.jpfgen.dir" value=".pageflow-struts-generated"/>
+
+    <!-- Define the classpath used to build the webapp -->
+    <path id="webapp.build.classpath">
+        <pathelement location="${servlet-api.jar}"/>
+        <pathelement location="${jsp-api.jar}"/>
+        <pathelement location="${webapp.dir}/WEB-INF/classes"/>
+        <fileset dir="${webapp.dir}/WEB-INF/lib">
+            <include name="*.jar"/>
+        </fileset>
+    </path>    
+
+    <target name="deploy-beehive" description="Copy the Beehive webapp rutime 
into the petstoreWeb webapp">
+        <deploy-netui webappDir="${webapp.dir}"/>
+        <deploy-wsm webappDir="${webapp.dir}"/>
     </target>
 
-    <target name="clean" description="Clean the petstoreWeb webapp">
-        <clean-webapp webappDir="${basedir}"/>
+    <target name="build" depends="deploy-beehive" description="Build the 
petstoreWeb webapp">
+        <available property="webapp.dir.available" file="${webapp.dir}" 
type="dir"/>
+        <fail unless="webapp.dir.available" message="Can't find the webapp 
directory ${webapp.dir}"/>
+
+        <!-- 
+            this directory needs to get whacked before every build so 
+            that control interface repackagings don't cause stale
+            files to be compiled 
+          -->
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
includeEmptyDirs="true"/>
+
+        <mkdir dir="${webapp.dir}/WEB-INF/classes"/>
+
+        <!-- compile XSDs -->
+        <build-schemas sourceDir="${webapp.dir}/WEB-INF/schemas" 
destDir="${webapp.dir}/WEB-INF/classes"/>
+
+        <!-- compile controls -->
+        <build-controls sourceDir="${webapp.dir}/WEB-INF/src" 
+                        destdir="${webapp.dir}/WEB-INF/classes" 
+                        tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"
+                        classpathRef="webapp.build.classpath"/>
+
+        <!-- compile JPFs -->
+        <build-pageflows sourceDir="${webapp.dir}" 
+                         destdir="${webapp.dir}/WEB-INF/classes" 
+                         tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"
+                         classpathRef="webapp.build.classpath"/>
+
+        <!-- copy resources -->
+       <echo>Copy all .properties and .xml files</echo>
+        <copy todir="${webapp.dir}/WEB-INF/classes">
+            <fileset dir="${webapp.dir}/WEB-INF/src" 
includes="**/*.properties"/>
+            <fileset dir="${webapp.dir}/WEB-INF/src" includes="**/*.xml"/>
+        </copy>
     </target>
 
-    <target name="war" description="Build a compressed WAR file that can be 
deployed to an application container">
-        <!-- note, this does *not* exclude source from the archive -->
-        <war destfile="${archive.dir}/${contextPath}.war" 
webxml="${basedir}/WEB-INF/web.xml">
-            <fileset dir="${basedir}"/>
-        </war>
+    <target name="clean" description="Clean the petstoreWeb">
+        <delete dir="${webapp.dir}/WEB-INF/classes" includeEmptyDirs="true"/>
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
includeEmptyDirs="true"/>
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.jpfgen.dir}" 
includeEmptyDirs="true"/>
     </target>
 
-    <target name="deploy-beehive" description="Copy the Beehive webapp rutime 
into the petstoreWeb webapp">
-        <deploy-netui webappDir="${basedir}"/>
-        <deploy-wsm webappDir="${basedir}"/>
+    <target name="war" description="Build a compressed WAR file that can be 
deployed to an application container">
+        <property name="archive.dir" value="${webapp.dir}/.."/>
+
+        <!-- this does *not* exclude source from the archive -->
+        <war destfile="${archive.dir}/${contextPath}.war" 
webxml="${webapp.dir}/WEB-INF/web.xml">
+            <fileset dir="${webapp.dir}">
+                <exclude name="WEB-INF/src/**"/>
+            </fileset>
+        </war>
     </target>
 
     <target name="usage" description="Print usage information for this build 
file">
@@ -58,11 +113,9 @@
 Once the webapp is built, it's ready to deploy onto your application container.
         </echo>
 
-        <target name="usage" description="Print the usage for this build.xml">
-            <java fork="no" classname="org.apache.tools.ant.Main">
-                <arg line="-f ${ant.file} -projecthelp"/>
-            </java>
-        </target>
+        <java fork="no" classname="org.apache.tools.ant.Main">
+            <arg line="-f ${ant.file} -projecthelp"/>
+        </java>
     </target>
 
 </project>

Added: incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build.properties
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build.properties?view=auto&rev=157286
==============================================================================
--- incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build.properties 
(added)
+++ incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build.properties 
Sat Mar 12 13:52:52 2005
@@ -0,0 +1,7 @@
+#
+#
+#
+beehive.home=../../../..
+
+servlet-api.jar=${os.CATALINA_HOME}/common/lib/servlet-api.jar
+jsp-api.jar=${os.CATALINA_HOME}/common/lib/jsp-api.jar
\ No newline at end of file

Propchange: 
incubator/beehive/trunk/samples/petstoreWeb/WEB-INF/src/build.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/test/dist-test/ant/build.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/test/dist-test/ant/build.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/test/dist-test/ant/build.xml (original)
+++ incubator/beehive/trunk/test/dist-test/ant/build.xml Sat Mar 12 13:52:52 
2005
@@ -21,6 +21,7 @@
           <antcall target="prepare.build"/>
 
           <antcall target="netui.tests" />
+          <sleep minutes="5"/>
           <antcall target="controls.tests" />
           <!-- antcall target="wsm.tests"/ -->
     </target>
@@ -44,6 +45,8 @@
     </target>
 
     <target name="prepare.build" if="build.present" description="Prepare test 
build area">
+       <copy todir="${dist.home}/ant" 
file="${test.home}/ant/testdist-buildWebapp.xml"/>
+
        <mkdir dir="build"/>
        <mkdir dir="build/webapps"/>
        <mkdir dir="build/testResults"/>

Modified: incubator/beehive/trunk/test/dist-test/ant/test-imports.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/test/dist-test/ant/test-imports.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/test/dist-test/ant/test-imports.xml (original)
+++ incubator/beehive/trunk/test/dist-test/ant/test-imports.xml Sat Mar 12 
13:52:52 2005
@@ -24,7 +24,7 @@
 
     <property environment="os"/>
     <dirname property="test.home" file="${ant.file.test-imports}"/>
-    <property name="dist.home" value="${test.home}/../@DIST-NAME@"/>
+    <property name="dist.home" 
value="${test.home}/../apache-beehive-incubating-svn-snapshot"/>
     <property name="build.dir" value="${test.home}/build"/>
     <property name="test.result.root" value="${build.dir}/testResults"/>
     <property name="test.webapp.root" value="${build.dir}/webapps"/>
@@ -44,7 +44,8 @@
         <attribute name="webappDir"/>
         <sequential>
             <echo>Build webapp ${webapp.dir}</echo>
-            <ant dir="${dist.home}/ant" antfile="buildWebapp.xml" 
target="build" inheritAll="false">
+            <ant dir="${test.home}/ant" antfile="testdist-buildWebapp.xml" 
target="build" inheritAll="false">
+                <property name="dist.home" location="${dist.home}"/>
                 <property name="webapp.dir" location="@{webappDir}"/>
             </ant>
         </sequential>
@@ -54,7 +55,8 @@
         <attribute name="webappDir"/>
         <sequential>
             <echo>Clean webapp ${webapp.dir}</echo>
-            <ant dir="${dist.home}/ant" antfile="buildWebapp.xml" 
target="clean" inheritAll="false">
+            <ant dir="${test.home}/ant" antfile="testdist-buildWebapp.xml" 
target="clean" inheritAll="false">
+                <property name="dist.home" location="${dist.home}"/>
                 <property name="webapp.dir" location="@{webappDir}"/>
             </ant>
         </sequential>

Added: incubator/beehive/trunk/test/dist-test/ant/testdist-buildWebapp.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/test/dist-test/ant/testdist-buildWebapp.xml?view=auto&rev=157286
==============================================================================
--- incubator/beehive/trunk/test/dist-test/ant/testdist-buildWebapp.xml (added)
+++ incubator/beehive/trunk/test/dist-test/ant/testdist-buildWebapp.xml Sat Mar 
12 13:52:52 2005
@@ -0,0 +1,77 @@
+<?xml version="1.0"?>
+
+<!--
+    This is a build file that is used for Beehive distribution testing and is 
required
+    to bridge the gap between the applications in the Beehive SVN tree and the
+    structure of the distribution.
+
+    The "build" and "clean" targets below need to be provided so that the 
+    NetUI and Controls webapps are able to be built using their existing
+    build files but with the tools / paths from the distribution.
+
+    In the end, this is a total HACK and needs to be reworked, but it's
+    a sufficient stopgap for now.
+-->
+<project name="Beehive/TestDist/WebappBuild" default="usage">
+
+    <property name="tmp.sourcegen.dir" value=".tmpbeansrc"/>
+    <property name="tmp.jpfgen.dir" value=".pageflow-struts-generated"/>
+
+    <import file="${dist.home}/beehive-imports.xml"/>
+    <import file="${dist.home}/ant/beehive-tools.xml"/>
+
+    <path id="appserver.build.classpath">
+        <fileset dir="${os.CATALINA_HOME}/common/lib">
+            <include name="*.jar"/>
+        </fileset>
+    </path>
+
+    <target name="build" description="Build a webapp given the webapp root as 
-Dwebapp.dir">
+        <available property="webapp.dir.available" file="${webapp.dir}" 
type="dir"/>
+        <fail unless="webapp.dir.available" message="Can't find the webapp 
directory ${webapp.dir}"/>
+
+        <!-- this is the classpath to include when building webapp sources -->
+        <path id="webapp.build.classpath">
+            <path refid="appserver.build.classpath"/>
+            <pathelement location="${webapp.dir}/WEB-INF/classes"/>
+            <fileset dir="${webapp.dir}/WEB-INF/lib">
+                <include name="*.jar"/>
+            </fileset>
+        </path>    
+
+        <!-- 
+            this directory needs to get whacked before every build so 
+            that control interface repackagings don't cause stale
+            files to be compiled 
+          -->
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
includeEmptyDirs="true"/>
+
+        <mkdir dir="${webapp.dir}/WEB-INF/classes"/>
+
+        <!-- compile XSDs -->
+        <build-schemas sourceDir="${webapp.dir}/WEB-INF/schemas" 
destDir="${webapp.dir}/WEB-INF/classes"/>
+
+        <!-- compile controls -->
+        <build-controls sourceDir="${webapp.dir}/WEB-INF/src" 
destdir="${webapp.dir}/WEB-INF/classes" 
tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
classpathRef="webapp.build.classpath"/>
+
+        <!-- compile JPFs -->
+        <build-pageflows sourceDir="${webapp.dir}" 
destdir="${webapp.dir}/WEB-INF/classes" 
tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
classpathRef="webapp.build.classpath"/>
+
+        <!-- copy resources -->
+       <echo>Copy all .properties and .xml files</echo>
+        <copy todir="${webapp.dir}/WEB-INF/classes">
+            <fileset dir="${webapp.dir}/WEB-INF/src" 
includes="**/*.properties"/>
+            <fileset dir="${webapp.dir}/WEB-INF/src" includes="**/*.xml"/>
+        </copy>
+    </target>
+
+    <target name="clean" description="Clean a webapp given the webapp root as 
-Dwebapp.dir">
+        <available property="webapp.dir.available" file="${webapp.dir}" 
type="dir"/>
+        <fail unless="webapp.dir.available" message="Can't find the webapp 
directory ${webapp.dir}"/>
+
+        <delete dir="${webapp.dir}/WEB-INF/classes" includeEmptyDirs="true"/>
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
includeEmptyDirs="true"/>
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.jpfgen.dir}" 
includeEmptyDirs="true"/>
+    </target>
+
+</project>
\ No newline at end of file

Propchange: incubator/beehive/trunk/test/dist-test/ant/testdist-buildWebapp.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: incubator/beehive/trunk/test/dist-test/build.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/test/dist-test/build.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/test/dist-test/build.xml (original)
+++ incubator/beehive/trunk/test/dist-test/build.xml Sat Mar 12 13:52:52 2005
@@ -48,8 +48,9 @@
             </copy>
 
             <copy todir="${test.dist.base.dir}/beehive-test-dist">
-                    <fileset dir="${beehive.home}/test/dist-test/ant" 
-                             includes="build.xml"/>
+                    <fileset dir="${beehive.home}/test/dist-test/ant">
+                        <include name="build.xml"/>
+                    </fileset>
             </copy>
 
             <copy todir="${test.dist.base.dir}/beehive-test-dist">
@@ -62,6 +63,7 @@
 
             <copy todir="${test.dist.base.dir}/beehive-test-dist/ant">
                 <fileset file="${beehive.home}/ant/*-imports.xml"/>
+                <fileset 
file="${beehive.home}/test/dist-test/ant/testdist-buildWebapp.xml"/>
             </copy> 
 
          <!-- Package the test distribution -->
@@ -114,5 +116,4 @@
             <tarfileset dir="${test.dist.base.dir}" 
excludes="**/*.zip,**/*.cmd"/>
         </tar>
       </target>
-
 </project>

Modified: incubator/beehive/trunk/user/beehive-imports.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/user/beehive-imports.xml?view=diff&r1=157285&r2=157286
==============================================================================
--- incubator/beehive/trunk/user/beehive-imports.xml (original)
+++ incubator/beehive/trunk/user/beehive-imports.xml Sat Mar 12 13:52:52 2005
@@ -24,31 +24,31 @@
 <project name="beehive-imports" default="" basedir=".">
 
     <property environment="os"/>
-    <dirname property="beehive.home" file="${ant.file.beehive-imports}"/>
+    <dirname property="this.dir" file="${ant.file.beehive-imports}"/>
 
     <path id="controls.dependency.path">
-        <pathelement location="${beehive.home}/lib/controls/controls.jar"/>
+        <pathelement location="${this.dir}/lib/controls/controls.jar"/>
     </path>
 
     <path id="netui-compiler.dependency.path">
-        <pathelement 
location="${beehive.home}/lib/netui/beehive-netui-compiler.jar"/>
+        <pathelement 
location="${this.dir}/lib/netui/beehive-netui-compiler.jar"/>
     </path>
 
     <path id="velocity.dependency.path">
-        <pathelement location="${beehive.home}/lib/controls/velocity-1.4.jar"/>
-        <pathelement 
location="${beehive.home}/lib/controls/velocity-dep-1.4.jar"/>
+        <pathelement location="${this.dir}/lib/controls/velocity-1.4.jar"/>
+        <pathelement location="${this.dir}/lib/controls/velocity-dep-1.4.jar"/>
     </path>
 
     <path id="xbean.dependency.path">
-        <pathelement location="${beehive.home}/lib/common/apache-xbean.jar"/>
-        <pathelement location="${beehive.home}/lib/common/jsr173_1.0_api.jar"/>
+        <pathelement location="${this.dir}/lib/common/apache-xbean.jar"/>
+        <pathelement location="${this.dir}/lib/common/jsr173_1.0_api.jar"/>
     </path>
 
     <macrodef name="deploy-netui">
         <attribute name="webappDir"/>
         <sequential>
             <echo>Deploy NetUI to webapp @{webappDir}</echo>
-            <ant antfile="${beehive.home}/ant/webappRuntimeCore.xml" 
target="deploy.beehive.webapp.runtime" inheritAll="false">
+            <ant antfile="${this.dir}/ant/webappRuntimeCore.xml" 
target="deploy.beehive.webapp.runtime" inheritAll="false">
                 <property name="webapp.dir" location="@{webappDir}"/>
             </ant>
         </sequential>
@@ -58,27 +58,7 @@
         <attribute name="webappDir"/>
         <sequential>
             <echo>Deploy WSM to webapp @{webappDir}</echo>
-            <ant antfile="${beehive.home}/ant/webappRuntimeCore.xml" 
target="deploy.wsm.webapp.runtime" inheritAll="false">
-                <property name="webapp.dir" location="@{webappDir}"/>
-            </ant>
-        </sequential>
-    </macrodef>
-
-    <macrodef name="build-webapp">
-        <attribute name="webappDir"/>
-        <sequential>
-            <echo>Build webapp @{webappDir}</echo>
-            <ant antfile="${beehive.home}/ant/buildWebapp.xml" target="build" 
inheritAll="false">
-                <property name="webapp.dir" location="@{webappDir}"/>
-            </ant>
-        </sequential>
-    </macrodef>
-
-    <macrodef name="clean-webapp">
-        <attribute name="webappDir"/>
-        <sequential>
-            <echo>Clean webapp @{webappDir}</echo>
-            <ant antfile="${beehive.home}/ant/buildWebapp.xml" target="clean" 
inheritAll="false">
+            <ant antfile="${this.dir}/ant/webappRuntimeCore.xml" 
target="deploy.wsm.webapp.runtime" inheritAll="false">
                 <property name="webapp.dir" location="@{webappDir}"/>
             </ant>
         </sequential>

Added: incubator/beehive/trunk/user/netui-blank/build.properties
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/user/netui-blank/build.properties?view=auto&rev=157286
==============================================================================
--- incubator/beehive/trunk/user/netui-blank/build.properties (added)
+++ incubator/beehive/trunk/user/netui-blank/build.properties Sat Mar 12 
13:52:52 2005
@@ -0,0 +1,7 @@
+#
+#
+#
+beehive.home=../../../..
+
+servlet-api.jar=${os.CATALINA_HOME}/common/lib/servlet-api.jar
+jsp-api.jar=${os.CATALINA_HOME}/common/lib/jsp-api.jar
\ No newline at end of file

Propchange: incubator/beehive/trunk/user/netui-blank/build.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/beehive/trunk/user/netui-blank/build.xml
URL: 
http://svn.apache.org/viewcvs/incubator/beehive/trunk/user/netui-blank/build.xml?view=auto&rev=157286
==============================================================================
--- incubator/beehive/trunk/user/netui-blank/build.xml (added)
+++ incubator/beehive/trunk/user/netui-blank/build.xml Sat Mar 12 13:52:52 2005
@@ -0,0 +1,121 @@
+<?xml version="1.0"?>
+<!--
+   Copyright 2004 The Apache Software Foundation.
+
+   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.
+  
+   $Header:$
+ -->
+
+<!--
+  An Ant build file for compiling the petstoreWeb Beehive sample web 
application.
+-->
+<project name="Beehive/Samples/netui-blank" default="usage" basedir="../..">
+
+    <property environment="os"/>
+    <property file="${basedir}/WEB-INF/src/build.properties"/>
+
+    <import file="${beehive.home}/beehive-imports.xml"/>
+    <import file="${beehive.home}/ant/beehive-tools.xml"/>
+
+    <property name="webapp.dir" location="${basedir}"/>
+    <property name="contextPath" value="netui-blank"/>
+
+    <property name="tmp.sourcegen.dir" value=".tmpbeansrc"/>
+    <property name="tmp.jpfgen.dir" value=".pageflow-struts-generated"/>
+
+    <!-- Define the classpath used to build the webapp -->
+    <path id="webapp.build.classpath">
+        <pathelement location="${servlet-api.jar}"/>
+        <pathelement location="${jsp-api.jar}"/>
+        <pathelement location="${webapp.dir}/WEB-INF/classes"/>
+        <fileset dir="${webapp.dir}/WEB-INF/lib">
+            <include name="*.jar"/>
+        </fileset>
+    </path>    
+
+    <target name="deploy-beehive" description="Copy the Beehive webapp rutime 
into the petstoreWeb webapp">
+        <deploy-netui webappDir="${webapp.dir}"/>
+        <deploy-wsm webappDir="${webapp.dir}"/>
+    </target>
+
+    <target name="build" depends="deploy-beehive" description="Build the 
petstoreWeb webapp">
+        <available property="webapp.dir.available" file="${webapp.dir}" 
type="dir"/>
+        <fail unless="webapp.dir.available" message="Can't find the webapp 
directory ${webapp.dir}"/>
+
+        <!-- 
+            this directory needs to get whacked before every build so 
+            that control interface repackagings don't cause stale
+            files to be compiled 
+          -->
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
includeEmptyDirs="true"/>
+
+        <mkdir dir="${webapp.dir}/WEB-INF/classes"/>
+
+        <!-- compile XSDs -->
+        <build-schemas sourceDir="${webapp.dir}/WEB-INF/schemas" 
destDir="${webapp.dir}/WEB-INF/classes"/>
+
+        <!-- compile controls -->
+        <build-controls sourceDir="${webapp.dir}/WEB-INF/src" 
+                        destdir="${webapp.dir}/WEB-INF/classes" 
+                        tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"
+                        classpathRef="webapp.build.classpath"/>
+
+        <!-- compile JPFs -->
+        <build-pageflows sourceDir="${webapp.dir}" 
+                         destdir="${webapp.dir}/WEB-INF/classes" 
+                         tmpdir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}"
+                         classpathRef="webapp.build.classpath"/>
+
+        <!-- copy resources -->
+       <echo>Copy all .properties and .xml files</echo>
+        <copy todir="${webapp.dir}/WEB-INF/classes">
+            <fileset dir="${webapp.dir}/WEB-INF/src" 
includes="**/*.properties"/>
+            <fileset dir="${webapp.dir}/WEB-INF/src" includes="**/*.xml"/>
+        </copy>
+    </target>
+
+    <target name="clean" description="Clean the petstoreWeb">
+        <delete dir="${webapp.dir}/WEB-INF/classes" includeEmptyDirs="true"/>
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.sourcegen.dir}" 
includeEmptyDirs="true"/>
+        <delete dir="${webapp.dir}/WEB-INF/${tmp.jpfgen.dir}" 
includeEmptyDirs="true"/>
+    </target>
+
+    <target name="war" description="Build a compressed WAR file that can be 
deployed to an application container">
+        <property name="archive.dir" value="${webapp.dir}/.."/>
+
+        <!-- this does *not* exclude source from the archive -->
+        <war destfile="${archive.dir}/${contextPath}.war" 
webxml="${webapp.dir}/WEB-INF/web.xml">
+            <fileset dir="${webapp.dir}">
+                <exclude name="WEB-INF/src/**"/>
+            </fileset>
+        </war>
+    </target>
+
+    <target name="usage" description="Print usage information for this build 
file">
+        <echo>
+Welcome to the Beehive petstoreWeb sample webapp!  
+
+To run the webapp, two steps need to occur:
+- copy the Beehive runtime to the webapp
+- build the webapp
+
+Once the webapp is built, it's ready to deploy onto your application container.
+        </echo>
+
+        <java fork="no" classname="org.apache.tools.ant.Main">
+            <arg line="-f ${ant.file} -projecthelp"/>
+        </java>
+    </target>
+
+</project>
\ No newline at end of file

Propchange: incubator/beehive/trunk/user/netui-blank/build.xml
------------------------------------------------------------------------------
    svn:eol-style = native


Reply via email to