blob: d2d56e4d4e48e8946359e43b8eb5de0211310886 [file] [log] [blame]
<?xml version="1.0"?>
<!--
Copyright (c) 2010 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 - Initial API and implementation
-->
<!--
Script for generating the PBS server packages. To be run with
PTP master build and not standalone.
-->
<project name="PBS Java Proxy Build" default="noDefault">
<tstamp/>
<property name="server.builddir" value="${build.result.folder}/pbs_proxy"/>
<property name="server.jar" value="${basedir}/../org.eclipse.ptp.rm.pbs.core.server/pbs_proxy.jar"/>
<target name="noDefault">
<echo message="This file must be called with explicit targets" />
</target>
<!-- ===================================================================== -->
<!-- Steps to do before the target build.jars -->
<!-- Available parameters : -->
<!-- build.result.folder - folder to contain the build results -->
<!-- ===================================================================== -->
<target name="pre.build.jars"/>
<!-- ===================================================================== -->
<!-- Steps to do after the target build.jars -->
<!-- Available parameters : -->
<!-- build.result.folder - folder to contain the build results -->
<!-- ===================================================================== -->
<target name="post.build.jars"/>
<!-- ===================================================================== -->
<!-- Steps to do before the target build.sources -->
<!-- Available parameters : -->
<!-- build.result.folder - folder to contain the build results -->
<!-- ===================================================================== -->
<target name="pre.build.sources"/>
<!-- ===================================================================== -->
<!-- Steps to do after the target build.sources -->
<!-- Available parameters : -->
<!-- build.result.folder - folder to contain the build results -->
<!-- ===================================================================== -->
<target name="post.build.sources"/>
<!-- ===================================================================== -->
<!-- Steps to do before the compilation target <name> -->
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
<!-- Available parameters : -->
<!-- source.foldern : n = 1 ... N, the source folders -->
<!-- target.folder : where the results of the compilation go -->
<!-- <name>.classpath : name = name of the compilation target. A -->
<!-- reference to the classpath structure. -->
<!-- ===================================================================== -->
<target name="pre.name"/>
<target name="pre.@dot"/>
<!-- ===================================================================== -->
<!-- Steps to do during the compilation target <name>, after the compile -->
<!-- but before jaring. Substitute "name" with the name of the compilation-->
<!-- target, eg @dot -->
<!-- Available parameters : -->
<!-- source.foldern : n = 1 ... N, the source folders -->
<!-- target.folder : where the results of the compilation go -->
<!-- <name>.classpath : name = name of the compilation target. A -->
<!-- reference to the classpath structure. -->
<!-- ===================================================================== -->
<target name="post.compile.name"/>
<target name="post.compile.@dot"/>
<!-- ===================================================================== -->
<!-- Steps to do after the compilation target <name> -->
<!-- Substitute "name" with the name of the compilation target, eg @dot -->
<!-- Available parameters : -->
<!-- jar.Location - the location of the compilation results -->
<!-- <name>.classpath : name = name of the compilation target. A -->
<!-- reference to the classpath structure. -->
<!-- ===================================================================== -->
<target name="post.name"/>
<target name="post.@dot"/>
<!-- ===================================================================== -->
<!-- Steps to do before the target gather.bin.parts -->
<!-- Available parameters : -->
<!-- build.result.folder - folder containing the build results -->
<!-- target.folder - destination folder -->
<!-- ===================================================================== -->
<target name="pre.gather.bin.parts"/>
<!-- ===================================================================== -->
<!-- Steps to do after the target gather.bin.parts -->
<!-- Available parameters : -->
<!-- build.result.folder - folder containing the build results -->
<!-- target.folder - destination folder -->
<!-- ===================================================================== -->
<target name="post.gather.bin.parts" depends="jar.remote"/>
<!-- ===================================================================== -->
<!-- Steps to do before the target gather.sources -->
<!-- Available parameters : -->
<!-- destination.temp.folder - destination folder -->
<!-- ===================================================================== -->
<target name="pre.gather.sources"/>
<!-- ===================================================================== -->
<!-- Steps to do after the target gather.sources -->
<!-- Available parameters : -->
<!-- destination.temp.folder - destination folder -->
<!-- ===================================================================== -->
<target name="post.gather.sources"/>
<!-- ===================================================================== -->
<!-- Steps to do before the target gather.logs -->
<!-- Available parameters : -->
<!-- destination.temp.folder - destination folder -->
<!-- ===================================================================== -->
<target name="pre.gather.logs"/>
<!-- ===================================================================== -->
<!-- Steps to do after the target gather.logs -->
<!-- Available parameters : -->
<!-- destination.temp.folder - destination folder -->
<!-- ===================================================================== -->
<target name="post.gather.logs"/>
<!-- ===================================================================== -->
<!-- Steps to do before the target clean -->
<!-- Available parameters : -->
<!-- destination.temp.folder - destination folder -->
<!-- ===================================================================== -->
<target name="pre.clean"/>
<!-- ===================================================================== -->
<!-- Steps to do after the target clean -->
<!-- Available parameters : -->
<!-- plugin.destination - final destination of the build -->
<!-- build.result.folder - results of the compilation -->
<!-- temp.folder - temporary folder -->
<!-- ===================================================================== -->
<target name="post.clean"/>
<target name="prepare.remote.jar">
<!-- Add the Jar-in-jar loader to the server -->
<unzip dest="${build.result.folder}">
<fileset dir="${basedir}/../../eclipse/plugins">
<include name="org.eclipse.jdt.ui_*.jar"/>
</fileset>
<patternset>
<include name="jar-in-jar-loader.zip"/>
</patternset>
</unzip>
<unzip src="jar-in-jar-loader.zip" dest="${server.builddir}"/>
<delete file="jar-in-jar-loader.zip"/>
</target>
<target name="assemble.remote">
<copy todir="${server.builddir}">
<fileset dir="${basedir}/../org.eclipse.ptp.utils.core">
<include name="utils_core.jar"/>
</fileset>
<fileset dir="${basedir}/../org.eclipse.ptp.proxy.protocol">
<include name="proxy_protocol.jar"/>
</fileset>
<fileset dir="${basedir}/../org.eclipse.ptp.rm.proxy.core">
<include name="rm_proxy_core.jar"/>
</fileset>
<fileset dir="${build.result.folder}/@dot"/>
<fileset dir="${build.result.folder}">
<include name="PBSAttributes/"/>
</fileset>
</copy>
</target>
<target name="jar.remote" depends="prepare.remote.jar, assemble.remote">
<jar destfile="${server.jar}" basedir="${server.builddir}">
<manifest>
<attribute name="Rsrc-Class-Path" value="./ utils_core.jar proxy_protocol.jar rm_proxy_core.jar"/>
<attribute name="Class-Path" value="."/>
<attribute name="Rsrc-Main-Class" value="org.eclipse.ptp.rm.pbs.jproxy.PBSProxyRuntimeServer"/>
<attribute name="Main-Class" value="org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader"/>
</manifest>
</jar>
</target>
</project>