ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 1 | <project name="Build specific targets and properties" default="noDefault"> |
| 2 | |
| 3 | <property name="postingDirectory" value="${buildDirectory}" /> |
| 4 | |
| 5 | <!-- ===================================================================== --> |
| 6 | <!-- Run a given ${target} on all elements being built --> |
| 7 | <!-- Add on <ant> task for each top level element being built. --> |
| 8 | <!-- ===================================================================== --> |
| 9 | <target name="allElements"> |
| 10 | <echo message="Target:${target} " /> |
| 11 | <echo message="basedir: ${basedir}" /> |
| 12 | <echo message="component: ${component}" /> |
| 13 | <echo message="buildDirectory: ${buildDirectory}" /> |
| 14 | <echo message="baseLocation: ${baseLocation}" /> |
| 15 | <ant antfile="${genericTargets}" target="${target}"> |
| 16 | <property name="type" value="feature" /> |
| 17 | <property name="id" value="org.eclipse.wst" /> |
| 18 | </ant> |
| 19 | </target> |
| 20 | |
| 21 | <!-- ===================================================================== --> |
| 22 | <!-- Targets to assemble the built elements for particular configurations --> |
| 23 | <!-- These generally call the generated assemble scripts (named in --> |
| 24 | <!-- ${assembleScriptName}) but may also add pre and post processing --> |
| 25 | <!-- Add one target for each root element and each configuration --> |
| 26 | <!-- ===================================================================== --> |
| 27 | |
| 28 | <target name="assemble.org.eclipse.wst"> |
| 29 | <property name="archiveName" value="wtp-wst-${buildId}.zip" /> |
| 30 | <ant antfile="${assembleScriptName}" dir="${buildDirectory}" /> |
| 31 | |
| 32 | <mkdir dir="${postingDirectory}/${buildLabel}/checksum" /> |
| 33 | <checksum file="${postingDirectory}/${buildLabel}/wtp-wst-${buildId}.zip" property="md5" /> |
| 34 | <echo message="${md5} *wtp-wst-${buildId}.zip" file="${postingDirectory}/${buildLabel}/checksum/wtp-wst-${buildId}.zip.md5" /> |
| 35 | |
| 36 | </target> |
| 37 | |
| 38 | <!-- ===================================================================== --> |
| 39 | <!-- Check out map files from correct repository --> |
| 40 | <!-- Replace values for cvsRoot, package and mapVersionTag as desired. --> |
| 41 | <!-- ===================================================================== --> |
| 42 | <target name="checkLocal"> |
ndai | d7c6c4e | 2005-09-13 18:07:51 +0000 | [diff] [blame] | 43 | <available property="mapsLocal" file="${buildDirectory}/maps/releng" /> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 44 | </target> |
| 45 | <target name="getMapFiles" depends="checkLocal" unless="mapsLocal"> |
| 46 | |
| 47 | <!-- *** change the repo info --> |
| 48 | <property name="mapCvsRoot" value=":${cvsProtocol}:${cvsUser}@${cvsServer}:${cvsRoot}" /> |
| 49 | <property name="mapVersionTag" value="HEAD" /> |
| 50 | <echo message="${mapCvsRoot} ${mapVersionTag} "> |
| 51 | </echo> |
ndai | d7c6c4e | 2005-09-13 18:07:51 +0000 | [diff] [blame] | 52 | <cvs cvsRoot="${mapCvsRoot}" package="releng/maps" dest="${buildDirectory}/maps" tag="${mapVersionTag}" /> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 53 | <!--tag the map files project--> |
| 54 | <antcall target="tagMapFiles" /> |
| 55 | </target> |
| 56 | |
| 57 | <target name="tagMapFiles" if="tagMaps"> |
ndai | a04ffd5 | 2005-09-14 16:28:32 +0000 | [diff] [blame^] | 58 | <cvs dest="${buildDirectory}/maps" command="tag v${buildType}${timestamp}" /> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 59 | </target> |
| 60 | |
| 61 | |
| 62 | <!-- ===================================================================== --> |
| 63 | <!-- Steps to do before setup --> |
| 64 | <!-- ===================================================================== --> |
| 65 | <target name="preSetup"> |
| 66 | </target> |
| 67 | |
| 68 | <!-- ===================================================================== --> |
| 69 | <!-- Steps to do after setup but before starting the build proper --> |
| 70 | <!-- ===================================================================== --> |
| 71 | <target name="postSetup"> |
| 72 | <dirname file="${ant.file}" property="component.dir" /> |
| 73 | <ant antfile="${component.dir}/dependency.xml" target="get"> |
ndai | d7c6c4e | 2005-09-13 18:07:51 +0000 | [diff] [blame] | 74 | <property name="dependency.properties" value="${buildDirectory}/maps/releng/maps/dependencies.properties" /> |
ndai | b8cedc8 | 2005-09-13 18:00:32 +0000 | [diff] [blame] | 75 | <property name="base.install.dir" value="${buildRoot}" /> |
| 76 | </ant> |
| 77 | |
| 78 | </target> |
| 79 | |
| 80 | <!-- ===================================================================== --> |
| 81 | <!-- Steps to do before fetching the build elements --> |
| 82 | <!-- ===================================================================== --> |
| 83 | <target name="preFetch"> |
| 84 | </target> |
| 85 | |
| 86 | <!-- ===================================================================== --> |
| 87 | <!-- Steps to do after fetching the build elements --> |
| 88 | <!-- ===================================================================== --> |
| 89 | <target name="postFetch"> |
| 90 | </target> |
| 91 | |
| 92 | <!-- ===================================================================== --> |
| 93 | <!-- Steps to do before generating the build scripts. --> |
| 94 | <!-- ===================================================================== --> |
| 95 | <target name="preGenerate"> |
| 96 | </target> |
| 97 | |
| 98 | <!-- ===================================================================== --> |
| 99 | <!-- Steps to do after generating the build scripts. --> |
| 100 | <!-- ===================================================================== --> |
| 101 | <target name="postGenerate"> |
| 102 | </target> |
| 103 | |
| 104 | |
| 105 | <!-- ===================================================================== --> |
| 106 | <!-- Steps to do before running the build.xmls for the elements being built. --> |
| 107 | <!-- ===================================================================== --> |
| 108 | <target name="preProcess"> |
| 109 | <replace dir="${buildDirectory}/plugins" value="${timestamp}" token="@build@"> |
| 110 | <include name="**/about.mappings" /> |
| 111 | </replace> |
| 112 | </target> |
| 113 | |
| 114 | <!-- ===================================================================== --> |
| 115 | <!-- Steps to do after running the build.xmls for the elements being built. --> |
| 116 | <!-- ===================================================================== --> |
| 117 | <target name="postProcess"> |
| 118 | <condition property="logsAvailable"> |
| 119 | <istrue value="${javacVerbose}" /> |
| 120 | </condition> |
| 121 | <antcall target="gatherLogs" /> |
| 122 | </target> |
| 123 | |
| 124 | |
| 125 | <!-- ===================================================================== --> |
| 126 | <!-- Steps to do before running assemble. --> |
| 127 | <!-- ===================================================================== --> |
| 128 | <target name="preAssemble"> |
| 129 | <ant antfile="${buildDirectory}/plugins/org.eclipse.wst.ws.explorer/build-war.xml"> |
| 130 | <property name="baseLocation" value="${baseLocation}" /> |
| 131 | <property name="basedir" value="${buildDirectory}/plugins/org.eclipse.wst.ws.explorer" /> |
| 132 | <property name="buildDirectory" value="${buildDirectory}" /> |
| 133 | </ant> |
| 134 | </target> |
| 135 | |
| 136 | <!-- ===================================================================== --> |
| 137 | <!-- Steps to do after running assemble. --> |
| 138 | <!-- ===================================================================== --> |
| 139 | <target name="postAssemble"> |
| 140 | </target> |
| 141 | |
| 142 | <!-- ===================================================================== --> |
| 143 | <!-- Steps to do after the build is done. --> |
| 144 | <!-- ===================================================================== --> |
| 145 | <target name="postBuild"> |
| 146 | </target> |
| 147 | |
| 148 | <!-- ===================================================================== --> |
| 149 | <!-- Steps to do to test the build results --> |
| 150 | <!-- ===================================================================== --> |
| 151 | <target name="test"> |
| 152 | </target> |
| 153 | |
| 154 | <!-- ===================================================================== --> |
| 155 | <!-- Steps to do to publish the build results --> |
| 156 | <!-- ===================================================================== --> |
| 157 | <target name="publish"> |
| 158 | </target> |
| 159 | |
| 160 | |
| 161 | <!-- ===================================================================== --> |
| 162 | <!-- Helper targets --> |
| 163 | <!-- ===================================================================== --> |
| 164 | <target name="gatherLogs" if="logsAvailable"> |
| 165 | <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" /> |
| 166 | <antcall target="allElements"> |
| 167 | <param name="target" value="gatherLogs" /> |
| 168 | </antcall> |
| 169 | |
| 170 | <unzip dest="${buildDirectory}/${buildLabel}/compilelogs" overwrite="true"> |
| 171 | <fileset dir="${buildDirectory}/features/org.eclipse.wst"> |
| 172 | <include name="*.log.zip" /> |
| 173 | </fileset> |
| 174 | </unzip> |
| 175 | </target> |
| 176 | |
| 177 | <target name="clean" unless="noclean"> |
| 178 | <antcall target="allElements"> |
| 179 | <param name="target" value="cleanElement" /> |
| 180 | </antcall> |
| 181 | </target> |
| 182 | |
| 183 | <!-- ===================================================================== --> |
| 184 | <!-- Default target --> |
| 185 | <!-- ===================================================================== --> |
| 186 | <target name="noDefault"> |
| 187 | <echo message="You must specify a target when invoking this file" /> |
| 188 | </target> |
| 189 | |
| 190 | </project> |