0N/A<?xml version="1.0"?>
0N/A<!--
193N/A Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
0N/A DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0N/A
0N/A This code is free software; you can redistribute it and/or modify it
0N/A under the terms of the GNU General Public License version 2 only, as
115N/A published by the Free Software Foundation. Oracle designates this
0N/A particular file as subject to the "Classpath" exception as provided
115N/A by Oracle in the LICENSE file that accompanied this code.
0N/A
0N/A This code is distributed in the hope that it will be useful, but WITHOUT
0N/A ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0N/A FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
0N/A version 2 for more details (a copy is included in the LICENSE file that
0N/A accompanied this code).
0N/A
0N/A You should have received a copy of the GNU General Public License version
0N/A 2 along with this work; if not, write to the Free Software Foundation,
0N/A Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0N/A
115N/A Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
115N/A or visit www.oracle.com if you need additional information or have any
115N/A questions.
0N/A-->
0N/A
84N/A<project name="jaxws" default="all" basedir=".">
84N/A
84N/A <!-- For 'ant -p' or 'ant -projecthelp' -->
84N/A
84N/A <description>
84N/A Ant build script for the ${ant.project.name} part of the jdk.
0N/A
84N/A Input Properties: (see build.properties for the ant defaults)
84N/A bootstrap.dir - dir with lib/javac.jar, added to javac bootclasspath
84N/A javac.debug - true or false for debug classfiles
84N/A javac.target - classfile version target
84N/A javac.source - source version
123N/A
123N/A Run 'make help' for help using the Makefile.
84N/A </description>
0N/A
84N/A <!-- Project build properties. -->
0N/A <property file="build.properties"/>
0N/A
325N/A <property name="jaxws.src.dir" value="src/share/jaxws_classes"/>
325N/A <property name="jaf.src.dir" value="src/share/jaf_classes"/>
325N/A <path id="src.dir.id">
325N/A <pathelement path="${jaxws.src.dir}"/>
325N/A <pathelement path="${jaf.src.dir}"/>
325N/A </path>
0N/A
84N/A <!-- Initialization of directories needed for build. -->
84N/A <target name="init">
0N/A <mkdir dir="${build.dir}"/>
0N/A <mkdir dir="${build.classes.dir}"/>
84N/A <mkdir dir="${dist.dir}"/>
84N/A <mkdir dir="${dist.lib.dir}"/>
84N/A </target>
84N/A
84N/A <!-- Sanity checks and settings -->
84N/A <target name="sanity"
84N/A depends="-javac-jar-exists"
84N/A description="Display settings of configuration values">
84N/A <echo message="${sanity.info}"/>
84N/A </target>
84N/A
84N/A <!-- Check for bootstrap javac.jar file, warn if missing. -->
84N/A <condition property="javac.jar.exists">
84N/A <available file="${javac.jar}" type="file"/>
84N/A </condition>
84N/A <target name="-javac-jar-exists"
84N/A unless="javac.jar.exists">
84N/A <echo message="WARNING: Cannot find ${javac.jar}"/>
0N/A </target>
0N/A
325N/A <!-- Create src.zip. -->
325N/A <target name="-dist-src-zip" depends="init">
325N/A <zip file="${dist.src.zip}" basedir="${jaxws.src.dir}"/>
325N/A <zip file="${dist.src.zip}" basedir="${jaf.src.dir}" update="true"/>
325N/A </target>
325N/A
84N/A <!-- Creation of distribution files to jdk build process. -->
84N/A <target name="dist"
325N/A depends="init, build, -dist-classes-jar, -dist-src-zip"
84N/A description="Create all built distribution files.">
84N/A </target>
84N/A <target name="-dist-classes-jar-uptodate"
325N/A depends="init">
84N/A <condition property="dist.classes.jar.uptodate">
84N/A <and>
84N/A <available file="${dist.classes.jar}" type="file"/>
84N/A <uptodate targetfile="${dist.classes.jar}">
84N/A <srcfiles dir="${build.classes.dir}" includes="**"/>
84N/A </uptodate>
84N/A </and>
84N/A </condition>
84N/A </target>
84N/A <target name="-dist-classes-jar"
325N/A depends="init, -dist-classes-jar-uptodate"
84N/A unless="dist.classes.jar.uptodate">
84N/A <delete file="${dist.classes.jar}"/>
84N/A <jar file="${dist.classes.jar}" basedir="${build.classes.dir}"/>
0N/A </target>
0N/A
325N/A <!-- Special build area setup. -->
325N/A <target name="-build-setup" depends="init">
325N/A <mkdir dir="${build.classes.dir}"/>
325N/A <copy todir="${build.classes.dir}">
325N/A <fileset dir="${jaxws.src.dir}"
325N/A includes="**/*.xsd, **/*.default, **/*.properties"
325N/A excludes="**/*.java, **/*.package.html"/>
325N/A </copy>
325N/A <replaceregexp match="#(.*)$" replace="#" flags="gm">
325N/A <fileset dir="${build.classes.dir}" includes="**/*.properties"/>
325N/A </replaceregexp>
325N/A
325N/A <mkdir dir="${build.classes.dir}/META-INF/services"/>
325N/A <copy todir="${build.classes.dir}/META-INF/services"
325N/A file="${jaxws.src.dir}/com/sun/tools/etc/META-INF/services/com.sun.tools.internal.xjc.Plugin"/>
325N/A <copy todir="${build.classes.dir}/META-INF/services"
325N/A file="${jaxws.src.dir}/com/sun/tools/etc/META-INF/services/com.sun.mirror.apt.AnnotationProcessorFactory"/>
325N/A <mkdir dir="${build.classes.dir}/com/sun/tools/internal/xjc/runtime"/>
325N/A <copy todir="${build.classes.dir}/com/sun/tools/internal/xjc/runtime">
325N/A <fileset dir="${jaxws.src.dir}/com/sun/tools/internal/xjc/runtime"
325N/A includes="**/*.java"
325N/A excludes="**/*.package.html"/>
325N/A </copy>
0N/A </target>
0N/A
84N/A <!-- Build (compilation) of sources to class files. -->
84N/A <target name="build"
123N/A depends="compile, -build-setup">
123N/A </target>
123N/A <target name="compile"
325N/A depends="init">
123N/A <mkdir dir="${build.classes.dir}"/>
94N/A <javac
94N/A includeAntRuntime="false"
94N/A classpath="${build.classes.dir}:${tools.jar}"
94N/A fork="true"
0N/A destdir="${build.classes.dir}"
0N/A memoryInitialSize="${javac.memoryInitialSize}"
0N/A memoryMaximumSize="${javac.memoryMaximumSize}"
62N/A source="${javac.source}"
53N/A debug="${javac.debug}"
84N/A target="${javac.target}">
84N/A <compilerarg value="-J-Xbootclasspath/p:${javac.jar}"/>
84N/A <compilerarg line="${javac.version.opt} ${javac.lint.opts} ${javac.no.jdk.warnings}"/>
84N/A <src refid="src.dir.id"/>
84N/A </javac>
84N/A </target>
84N/A
84N/A <!-- Test. (FIXME: Need to know how to run tests.) -->
84N/A <target name="test"
325N/A depends="init, dist">
84N/A <echo message="FIXME: How do you run the tests"/>
84N/A </target>
84N/A
84N/A <!-- Populate source area if needed. -->
84N/A <target name="source"
325N/A depends="init"
84N/A description="Populate all source file directories">
0N/A </target>
0N/A
84N/A <!-- Clean up compiled files. -->
84N/A <target name="clean"
84N/A description="Delete all generated files">
84N/A <delete dir="${build.dir}"/>
84N/A <delete dir="${dist.dir}"/>
84N/A </target>
84N/A
84N/A <!-- Clean up compiled files and all imported source files. -->
84N/A <target name="clobber"
84N/A depends="clean"
84N/A description="Delete all generated files, including imported sources">
0N/A </target>
0N/A
84N/A <target name="-banner">
84N/A <echo message="+---------------------------------------+"/>
84N/A <echo message="+ Starting ant project ${ant.project.name} +"/>
84N/A <echo message="+---------------------------------------+"/>
84N/A </target>
84N/A
84N/A <!-- Do everything but test. -->
84N/A <target name="all"
84N/A depends="-banner, sanity, dist"
84N/A description="Build everything.">
84N/A <echo message="+---------------------------------------+"/>
84N/A <echo message="+ Finishing ant project ${ant.project.name}"/>
84N/A <echo message="+---------------------------------------+"/>
0N/A </target>
0N/A
0N/A</project>