| <?xml version="1.0" encoding="UTF-8"?> |
| <!-- ====================================================================== |
| Aug 30, 2007 11:28:45 PM |
| |
| epp |
| Build the epp project plugins with the PDE build system |
| |
| Mark Russell |
| ====================================================================== --> |
| <project name="epp" default="build"> |
| <description> |
| Build the epp project plugins with the PDE build system |
| </description> |
| |
| <import file="pde-macros.xml"/> |
| |
| <!-- ================================= |
| target: build |
| ================================= --> |
| <target name="build" depends="init,cleanup,setup,copy" description="--> Build the epp project plugins with the PDE build system"> |
| <dirname file="${ant.file}" property="epp.base.run.script" /> |
| <property name="epp.builder" location="${epp.base.run.script}/epp.features"/> |
| |
| <pdeRunBuild pdeBuilder="${epp.builder}"/> |
| |
| <copy todir="${build.out}"> |
| <fileset dir="${build.loc}/${pde.build.properties.file.buildLabel}"/> |
| </copy> |
| </target> |
| |
| |
| |
| <!-- - - - - - - - - - - - - - - - - - |
| target: init |
| - - - - - - - - - - - - - - - - - --> |
| <target name="init"> |
| <tstamp /> |
| <pdeInit/> |
| <property name="epp.build.base" value="${build.temp}/epp.build" /> |
| <property name="build.loc" location="${build.temp}/eclipse.build" /> |
| <property name="eclipse.sdk.zip.dir" location="/opt/eclipses" /> |
| <property name="eclipse.sdk.zip.file" value="eclipse-SDK-3.3-win32.zip" /> |
| <property name="eclipse.deltapack.zip.dir" location="/opt/eclipses" /> |
| <property name="eclipse.deltapack.zip.file" value="eclipse-RCP-3.3-delta-pack.zip" /> |
| <property name="eclipse.sdk.zip" location="${eclipse.sdk.zip.dir}/${eclipse.sdk.zip.file}" /> |
| <property name="eclipse.deltapack.zip" location="${eclipse.deltapack.zip.dir}/${eclipse.deltapack.zip.file}" /> |
| <property name="epp.build.id" value="${build.num}" /> |
| <property prefix="pde.build.properties.file" file="epp.features/build.properties" /> |
| <echo>baseLocation = ${pde.build.properties.file.baseLocation}</echo> |
| <fail> |
| Could not find the eclipse SDK zip file. Please set eclipse.sdk.zip to a valid directory |
| current value ${eclipse.sdk.zip} |
| e.g. if eclipse zip is in c:\downloads then set eclipse.zip to c:\downloads\eclipse-SDK-3.3-win32.zip |
| e.g. eclipse.sdk.zip=c:\downloads\eclipse-SDK-3.3-win32.zip |
| <condition> |
| <not> |
| <available file="${eclipse.sdk.zip}" type="file" /> |
| </not> |
| </condition> |
| </fail> |
| <fail> |
| Could not find the eclipse delta pack zip file please set eclipse.deltapack.zip to a valid directory |
| current value ${eclipse.deltapack.zip} |
| e.g. if eclipse zip is in c:\downloads then set eclipse.deltapack.zip to c:\downloads\eclipse-RCP-3.3-delta-pack.zip |
| e.g. eclipse.zip=c:\downloads\eclipse-RCP-3.3-delta-pack.zip |
| <condition> |
| <not> |
| <available file="${eclipse.deltapack.zip}" type="file" /> |
| </not> |
| </condition> |
| </fail> |
| </target> |
| |
| <!-- - - - - - - - - - - - - - - - - - |
| target: setup |
| - - - - - - - - - - - - - - - - - --> |
| <target name="setup" unless="skip.unzip.eclipse"> |
| <pdeSetup base="${pde.build.properties.file.base}" |
| baseLocation="${pde.build.properties.file.baseLocation}" |
| eclipseSdkZip="${eclipse.sdk.zip}" |
| eclipseDeltapackZip="${eclipse.deltapack.zip}" /> |
| |
| </target> |
| |
| <!-- - - - - - - - - - - - - - - - - - |
| target: cleanup |
| - - - - - - - - - - - - - - - - - --> |
| <target name="cleanup" unless="skip.unzip.eclipse"> |
| <pdeCleanup base="${pde.build.properties.file.base}"/> |
| </target> |
| |
| <!-- - - - - - - - - - - - - - - - - - |
| target: copy |
| - - - - - - - - - - - - - - - - - --> |
| <target name="copy"> |
| <property name="epp.plugins.loc" location="${epp.plugins.dir}" /> |
| <property name="epp.features.loc" location="${epp.features.dir}" /> |
| <pdeCopy builddirectory="${pde.build.properties.file.buildDirectory}" |
| pluginsdir="${epp.plugins.loc}" |
| featuresdir="${epp.features.loc}" |
| postprocessingtarget="post_copy_processing"> |
| <pluginsFileset> |
| <fileset dir="${epp.plugins.loc}"> |
| <include name="org.eclipse.epp.*/**" /> |
| <exclude name="*feature/**"/> |
| </fileset> |
| </pluginsFileset> |
| <featuresfileset> |
| <fileset dir="${epp.features.loc}"> |
| <include name="org.eclipse.epp.*feature/**" /> |
| </fileset> |
| </featuresfileset> |
| </pdeCopy> |
| </target> |
| |
| <!-- - - - - - - - - - - - - - - - - - |
| target: post_copy_processing |
| handle the rename of the features to match the feature id |
| - - - - - - - - - - - - - - - - - --> |
| <target name="post_copy_processing"> |
| <echo>rename directories to match the plugin id's</echo> |
| <echo>${buildFeaturesDir}/org.eclipse.epp.installer-feature to ${buildFeaturesDir}/org.eclipse.epp.installer</echo> |
| <move todir="${buildFeaturesDir}/org.eclipse.epp.installer"> |
| <fileset dir="${buildFeaturesDir}/org.eclipse.epp.installer-feature" /> |
| </move> |
| <echo>${buildFeaturesDir}/org.eclipse.epp.installer.tools-feature to ${buildFeaturesDir}/org.eclipse.epp.installer.tools</echo> |
| <move todir="${buildFeaturesDir}/org.eclipse.epp.installer.tools"> |
| <fileset dir="${buildFeaturesDir}/org.eclipse.epp.installer.tools-feature" /> |
| </move> |
| |
| </target> |
| </project> |