blob: 4e00d191cfbc0cd3aef725b7ba84abeb97c501ab [file] [log] [blame]
<?xml version="1.0"?>
<!--
Copyright 2005 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.
-->
<project name="Wap Demo" default="install">
<property name="root.dir" value="../.."/>
<property file="${root.dir}/config/Version.properties"/>
<property file="${root.dir}/config/build.properties"/>
<property file="${root.dir}/config/common.properties"/>
<path id="jetty.classpath">
<fileset dir="${jetty.dir}">
<include name="**/javax.*.jar"/>
</fileset>
</path>
<path id="compile.classpath">
<fileset dir="${root.lib.dir}">
<include name="*.jar"/>
<include name="${ext.dir}/*.jar"/>
<include name="${j2ee.dir}/*.jar"/>
</fileset>
</path>
<target name="init">
<mkdir dir="${classes.dir}"/>
</target>
<target name="clean">
<delete dir="${classes.dir}"/>
</target>
<target name="compile" depends="init"
description="Compile all classes in the tutorial.">
<javac srcdir="${src.dir}" destdir="${classes.dir}" debug="on"
target="1.1">
<classpath refid="compile.classpath"/>
</javac>
</target>
<target name="install" depends="compile"
description="Compile all classes and build the installed WAR.">
<mkdir dir="${examples.dir}"/>
<war warfile="${examples.dir}/${wap.war}"
webxml="context/WEB-INF/web.xml">
<fileset dir="context">
<exclude name="WEB-INF/web.xml"/>
</fileset>
<classes dir="${classes.dir}"/>
<classes dir="${src.dir}">
<exclude name="**/*.java"/>
<exclude name="**/package.html"/>
</classes>
</war>
</target>
<target name="run" description="Run the Wap Demo."
depends="compile">
<property environment="env"/>
<java classname="org.mortbay.jetty.Server" fork="true">
<classpath>
<!-- Favor files in src over copies in classes -->
<pathelement location="${src.dir}"/>
<pathelement location="${classes.dir}"/>
<path refid="compile.classpath"/>
<path refid="jetty.classpath"/>
<pathelement location="${env.JAVA_HOME}/lib/tools.jar"/>
<fileset dir="${jetty.dir}">
<include name="ext/*.jar"/>
<include name="lib/org.mortbay.jetty-jdk1.2.jar"/>
</fileset>
<fileset dir="${root.lib.dir}">
<include name="${runtime.dir}/*.jar"/>
</fileset>
<pathelement location="${root.dir}/config"/>
</classpath>
<arg value="jetty.xml"/>
<!-- Enable debugging on port 20150 -->
<jvmarg line="-showversion -Xdebug -Xnoagent"/>
<jvmarg
line="-Xrunjdwp:transport=dt_socket,suspend=n,server=y,address=20150"
/>
<sysproperty key="java.compiler" value="NONE"/>
<sysproperty key="org.apache.tapestry.disable-caching" value="true"/>
<sysproperty key="org.apache.tapestry.enable-reset-service" value="true"
/>
<sysproperty key="org.mortbay.util.FileResource.checkAliases"
value="false"/>
</java>
</target>
</project>