blob: 99361f39773d7c00a7aa6a3784bdbadd2f0284ef [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2009, 2014 IBM Corporation and others.
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License v1.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v10.html
Contributors:
IBM Corporation - initial API and implementation
-->
<!--
Build file used only by internal SWT build that generates the libraries & tags.
lib.dir is set to point to xmltask.jar on the internal hudson used to build SWT libraries.
This can be overriden by setting the property on commandline.
-->
<project name="swtinternalbuild" basedir=".">
<property name="repo.src" value="../../../eclipse.platform.swt"/>
<property name="repo.bin" value="../../../eclipse.platform.swt.binaries"/>
<property name="file_src_pom" value="bundles/org.eclipse.swt/pom.xml"/>
<property name="file_bin_parent_pom" value="bundles/binaries-parent/pom.xml"/>
<property name="lib.dir" value="/var/lib/hudson/antlib"/>
<taskdef name="xmltask" classname="com.oopsconsultancy.xmltask.ant.XmlTask">
<classpath>
<pathelement location="${lib.dir}/xmltask.jar"/>
</classpath>
</taskdef>
<!-- generates the time-stamp qualifiers and updates the pom files in source and binaries repo-->
<target name="generate_qualifier">
<tstamp><format property="build.qualifier" pattern="yyyyMMdd-HHmm"/></tstamp>
<echo>${build.qualifier}</echo>
</target>
<target name="write_qualifier" depends="generate_qualifier" description="writes the generated qualifier in pom.xml in src and binaries repo">
<xmltask source="${repo.src}/${file_src_pom}" dest="${repo.src}/${file_src_pom}" failWithoutMatch="true">
<replace path="/:project/:properties/:forceContextQualifier/text()" withText="v${build.qualifier}"/>
</xmltask>
<xmltask source="${repo.bin}/${file_bin_parent_pom}" dest="${repo.bin}/${file_bin_parent_pom}" failWithoutMatch="true">
<replace path="/:project/:properties/:forceContextQualifier/text()" withText="v${build.qualifier}"/>
</xmltask>
</target>
</project>