annotate build.xml @ 1203:b0dd986766bc

Added tag jdk7u80-b15 for changeset f6417ecaede6
author asaha
date Fri, 10 Apr 2015 09:20:47 -0700
parents 15dfd3addae0
children
rev   line source
duke@0 1 <?xml version="1.0"?>
duke@0 2 <!--
ohair@247 3 Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
duke@0 4 DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
duke@0 5
duke@0 6 This code is free software; you can redistribute it and/or modify it
duke@0 7 under the terms of the GNU General Public License version 2 only, as
ohair@149 8 published by the Free Software Foundation. Oracle designates this
duke@0 9 particular file as subject to the "Classpath" exception as provided
ohair@149 10 by Oracle in the LICENSE file that accompanied this code.
duke@0 11
duke@0 12 This code is distributed in the hope that it will be useful, but WITHOUT
duke@0 13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
duke@0 14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
duke@0 15 version 2 for more details (a copy is included in the LICENSE file that
duke@0 16 accompanied this code).
duke@0 17
duke@0 18 You should have received a copy of the GNU General Public License version
duke@0 19 2 along with this work; if not, write to the Free Software Foundation,
duke@0 20 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
duke@0 21
ohair@149 22 Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
ohair@149 23 or visit www.oracle.com if you need additional information or have any
ohair@149 24 questions.
duke@0 25 -->
duke@0 26
ohair@103 27 <project name="jaxws" default="all" basedir=".">
ohair@103 28
ohair@103 29 <!-- For 'ant -p' or 'ant -projecthelp' -->
ohair@103 30
ohair@103 31 <description>
ohair@103 32 Ant build script for the ${ant.project.name} part of the jdk.
duke@0 33
ohair@103 34 Input Properties: (see build.properties for the ant defaults)
ohair@103 35 bootstrap.dir - dir with lib/javac.jar, added to javac bootclasspath
ohair@103 36 javac.debug - true or false for debug classfiles
ohair@103 37 javac.target - classfile version target
ohair@103 38 javac.source - source version
ohair@158 39
ohair@158 40 Run 'make help' for help using the Makefile.
ohair@103 41 </description>
duke@0 42
ohair@103 43 <!-- Project build properties. -->
duke@0 44 <property file="build.properties"/>
duke@0 45
ohair@396 46 <property name="jaxws.src.dir" value="src/share/jaxws_classes"/>
ohair@396 47 <property name="jaf.src.dir" value="src/share/jaf_classes"/>
ohair@396 48 <path id="src.dir.id">
ohair@396 49 <pathelement path="${jaxws.src.dir}"/>
ohair@396 50 <pathelement path="${jaf.src.dir}"/>
ohair@396 51 </path>
ohair@103 52
ohair@103 53 <!-- Initialization of directories needed for build. -->
ohair@103 54 <target name="init">
ohair@103 55 <mkdir dir="${build.dir}"/>
ohair@103 56 <mkdir dir="${build.classes.dir}"/>
ohair@103 57 <mkdir dir="${dist.dir}"/>
ohair@103 58 <mkdir dir="${dist.lib.dir}"/>
ohair@103 59 </target>
ohair@103 60
ohair@103 61 <!-- Sanity checks and settings -->
ohair@103 62 <target name="sanity"
ohair@103 63 depends="-javac-jar-exists"
ohair@103 64 description="Display settings of configuration values">
ohair@103 65 <echo message="${sanity.info}"/>
duke@0 66 </target>
duke@0 67
ohair@103 68 <!-- Check for bootstrap javac.jar file, warn if missing. -->
ohair@103 69 <condition property="javac.jar.exists">
ohair@103 70 <available file="${javac.jar}" type="file"/>
ohair@103 71 </condition>
ohair@103 72 <target name="-javac-jar-exists"
ohair@103 73 unless="javac.jar.exists">
ohair@103 74 <echo message="WARNING: Cannot find ${javac.jar}"/>
duke@0 75 </target>
duke@0 76
ohair@396 77 <!-- Create src.zip. -->
ohair@396 78 <target name="-dist-src-zip" depends="init">
ohair@396 79 <zip file="${dist.src.zip}" basedir="${jaxws.src.dir}"/>
ohair@396 80 <zip file="${dist.src.zip}" basedir="${jaf.src.dir}" update="true"/>
ohair@396 81 </target>
ohair@396 82
ohair@103 83 <!-- Creation of distribution files to jdk build process. -->
ohair@103 84 <target name="dist"
ohair@396 85 depends="init, build, -dist-classes-jar, -dist-src-zip"
ohair@103 86 description="Create all built distribution files.">
ohair@103 87 </target>
ohair@103 88 <target name="-dist-classes-jar-uptodate"
ohair@396 89 depends="init">
ohair@103 90 <condition property="dist.classes.jar.uptodate">
ohair@103 91 <and>
ohair@103 92 <available file="${dist.classes.jar}" type="file"/>
ohair@103 93 <uptodate targetfile="${dist.classes.jar}">
ohair@103 94 <srcfiles dir="${build.classes.dir}" includes="**"/>
ohair@103 95 </uptodate>
ohair@103 96 </and>
ohair@103 97 </condition>
ohair@103 98 </target>
ohair@103 99 <target name="-dist-classes-jar"
ohair@396 100 depends="init, -dist-classes-jar-uptodate"
ohair@103 101 unless="dist.classes.jar.uptodate">
ohair@103 102 <delete file="${dist.classes.jar}"/>
ohair@103 103 <jar file="${dist.classes.jar}" basedir="${build.classes.dir}"/>
duke@0 104 </target>
duke@0 105
ohair@396 106 <!-- Special build area setup. -->
ohair@396 107 <target name="-build-setup" depends="init">
ohair@396 108 <mkdir dir="${build.classes.dir}"/>
ohair@396 109 <copy todir="${build.classes.dir}">
ohair@396 110 <fileset dir="${jaxws.src.dir}"
ohair@396 111 includes="**/*.xsd, **/*.default, **/*.properties"
ohair@396 112 excludes="**/*.java, **/*.package.html"/>
ohair@396 113 </copy>
ohair@396 114 <replaceregexp match="#(.*)$" replace="#" flags="gm">
ohair@396 115 <fileset dir="${build.classes.dir}" includes="**/*.properties"/>
ohair@396 116 </replaceregexp>
ohair@396 117
ohair@396 118 <mkdir dir="${build.classes.dir}/META-INF/services"/>
ohair@396 119 <copy todir="${build.classes.dir}/META-INF/services"
ohair@396 120 file="${jaxws.src.dir}/com/sun/tools/etc/META-INF/services/com.sun.tools.internal.xjc.Plugin"/>
ohair@396 121 <copy todir="${build.classes.dir}/META-INF/services"
ohair@396 122 file="${jaxws.src.dir}/com/sun/tools/etc/META-INF/services/com.sun.mirror.apt.AnnotationProcessorFactory"/>
ohair@396 123 <mkdir dir="${build.classes.dir}/com/sun/tools/internal/xjc/runtime"/>
ohair@396 124 <copy todir="${build.classes.dir}/com/sun/tools/internal/xjc/runtime">
ohair@396 125 <fileset dir="${jaxws.src.dir}/com/sun/tools/internal/xjc/runtime"
ohair@396 126 includes="**/*.java"
ohair@396 127 excludes="**/*.package.html"/>
ohair@396 128 </copy>
duke@0 129 </target>
duke@0 130
ohair@103 131 <!-- Build (compilation) of sources to class files. -->
ohair@103 132 <target name="build"
ohair@158 133 depends="compile, -build-setup">
ohair@158 134 </target>
ohair@158 135 <target name="compile"
ohair@396 136 depends="init">
ohair@158 137 <mkdir dir="${build.classes.dir}"/>
ohair@117 138 <javac
ohair@117 139 includeAntRuntime="false"
ohair@117 140 classpath="${build.classes.dir}:${tools.jar}"
ohair@117 141 fork="true"
duke@0 142 destdir="${build.classes.dir}"
duke@0 143 memoryInitialSize="${javac.memoryInitialSize}"
duke@0 144 memoryMaximumSize="${javac.memoryMaximumSize}"
jjg@76 145 source="${javac.source}"
aph@66 146 debug="${javac.debug}"
ohair@103 147 target="${javac.target}">
ohair@103 148 <compilerarg value="-J-Xbootclasspath/p:${javac.jar}"/>
ohair@103 149 <compilerarg line="${javac.version.opt} ${javac.lint.opts} ${javac.no.jdk.warnings}"/>
ohair@103 150 <src refid="src.dir.id"/>
ohair@103 151 </javac>
duke@0 152 </target>
duke@0 153
ohair@103 154 <!-- Test. (FIXME: Need to know how to run tests.) -->
ohair@103 155 <target name="test"
ohair@396 156 depends="init, dist">
ohair@103 157 <echo message="FIXME: How do you run the tests"/>
ohair@103 158 </target>
ohair@103 159
ohair@103 160 <!-- Populate source area if needed. -->
ohair@103 161 <target name="source"
ohair@396 162 depends="init"
ohair@103 163 description="Populate all source file directories">
duke@0 164 </target>
duke@0 165
ohair@103 166 <!-- Clean up compiled files. -->
ohair@103 167 <target name="clean"
ohair@103 168 description="Delete all generated files">
ohair@103 169 <delete dir="${build.dir}"/>
ohair@103 170 <delete dir="${dist.dir}"/>
ohair@103 171 </target>
ohair@103 172
ohair@103 173 <!-- Clean up compiled files and all imported source files. -->
ohair@103 174 <target name="clobber"
ohair@103 175 depends="clean"
ohair@103 176 description="Delete all generated files, including imported sources">
ohair@103 177 </target>
ohair@103 178
ohair@103 179 <target name="-banner">
ohair@103 180 <echo message="+---------------------------------------+"/>
ohair@103 181 <echo message="+ Starting ant project ${ant.project.name} +"/>
ohair@103 182 <echo message="+---------------------------------------+"/>
ohair@103 183 </target>
ohair@103 184
ohair@103 185 <!-- Do everything but test. -->
ohair@103 186 <target name="all"
ohair@103 187 depends="-banner, sanity, dist"
ohair@103 188 description="Build everything.">
ohair@103 189 <echo message="+---------------------------------------+"/>
ohair@103 190 <echo message="+ Finishing ant project ${ant.project.name}"/>
ohair@103 191 <echo message="+---------------------------------------+"/>
duke@0 192 </target>
duke@0 193
duke@0 194 </project>