summaryrefslogtreecommitdiffstats
path: root/eclipse.plugin/build.xml
diff options
context:
space:
mode:
authorwisberg <wisberg>2005-06-03 10:33:22 +0000
committerwisberg <wisberg>2005-06-03 10:33:22 +0000
commitc7e5498d3d5713693ae763ffab34571ca029cca2 (patch)
treeb4429e206d31090ba09cf98c05e5b928c11dec82 /eclipse.plugin/build.xml
parent845da1dc8a6a8154330a63fe6da5710bfa3dfc83 (diff)
downloadaspectj-c7e5498d3d5713693ae763ffab34571ca029cca2.tar.gz
aspectj-c7e5498d3d5713693ae763ffab34571ca029cca2.zip
proposed refactored script - still using targets in release/build.xml for now
Diffstat (limited to 'eclipse.plugin/build.xml')
-rw-r--r--eclipse.plugin/build.xml156
1 files changed, 156 insertions, 0 deletions
diff --git a/eclipse.plugin/build.xml b/eclipse.plugin/build.xml
new file mode 100644
index 000000000..cbb70b916
--- /dev/null
+++ b/eclipse.plugin/build.xml
@@ -0,0 +1,156 @@
+<!-- ====================================================================== -->
+<!-- Copyright (c) 2005 Contributors -->
+<!-- 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: (See CVS checkin's) -->
+<!-- ====================================================================== -->
+
+<project name="eclipse.plugins" default="eclipse.plugins" basedir=".">
+ <import file="${basedir}/../build/build-properties.xml" />
+
+ <target name="info">
+ <echo>
+ Assembles the Eclipse plugins.
+
+ Relies on ../build/build-properties.xml for some definitions, and
+ the build must have produced the AspectJ distribution already.
+
+ Define $${build.version.eclipse.plugins} to avoid "9.9.9" for
+ "DEVELOPMENT" (the default).
+ </echo>
+ </target>
+
+ <target name="init-eclipse-plugins" depends="init-properties">
+ <property name="ep.dir"
+ location="${aspectj.modules.dir}/eclipse.plugin"
+ />
+
+ <condition property="build.version.eclipse.plugins"
+ value="9.9.9"
+ >
+ <equals arg1="DEVELOPMENT" arg2="${build.version.long}" />
+ </condition>
+ <condition property="build.version.eclipse.plugins"
+ value="${build.version.long}"
+ >
+ <not>
+ <equals arg1="DEVELOPMENT"
+ arg2="${build.version.long}"
+ />
+ </not>
+ </condition>
+ <jar-property name="ep.aspectjrt.jar"
+ location="${aj.dist.dir}/tools/lib/aspectjrt.jar"
+ />
+ <property name="ep.eclipse.dist.dir"
+ location="${aj.dist.dir}/ide/eclipse"
+ />
+ </target>
+
+ <target name="eclipse.plugins"
+ depends="do-rt,do-source,do-ajde,do-doc"
+ />
+
+ <target name="do-rt" depends="init-eclipse-plugins">
+
+ <property name="name.rt" value="org.aspectj.aspectjrt" />
+ <mkdir dir="${ep.eclipse.dist.dir}/${name.rt}" />
+ <copy todir="${ep.eclipse.dist.dir}/${name.rt}"
+ file="${ep.aspectjrt.jar}"
+ />
+ <build-eclipse-plugin name="${name.rt}" />
+ </target>
+
+ <target name="do-source" depends="init-eclipse-plugins">
+ <property name="name.source"
+ value="org.aspectj.ajde.source"
+ />
+ <clean-dir dir="${ep.eclipse.dist.dir}/${name.source}/src" />
+ <copy todir="${ep.eclipse.dist.dir}/${name.source}/src"
+ file="${aspectj.modules.dir}/org.eclipse.jdt.core/jdtcore-for-aspectj-src.zip"
+ />
+ <!-- verify source dirs included:
+ grep 'kind="src"' */.classpath | sed '/testsrc/d;/path="\//d;s|\/.*path="|\/|;s|".*||'
+ -->
+ <zip destfile="${ep.eclipse.dist.dir}/${name.source}/src/aspectjsrc.zip"
+ >
+ <fileset dir="${aspectj.modules.dir}/ajbrowser/src" />
+ <fileset dir="${aspectj.modules.dir}/ajde/src" />
+ <fileset dir="${aspectj.modules.dir}/ajdoc/src" />
+ <fileset dir="${aspectj.modules.dir}/asm/src" />
+ <fileset dir="${aspectj.modules.dir}/aspectj5rt/java5-src"
+ />
+ <fileset dir="${aspectj.modules.dir}/aspectj5rt/src" />
+ <fileset dir="${aspectj.modules.dir}/bridge/src" />
+ <fileset dir="${aspectj.modules.dir}/loadtime/src" />
+ <fileset dir="${aspectj.modules.dir}/loadtime5/java5-src"
+ />
+ <fileset dir="${aspectj.modules.dir}/org.aspectj.ajdt.core/src"
+ />
+ <fileset dir="${aspectj.modules.dir}/org.aspectj.lib/src"
+ />
+ <fileset dir="${aspectj.modules.dir}/runtime/src" />
+ <fileset dir="${aspectj.modules.dir}/taskdefs/src" />
+ <fileset dir="${aspectj.modules.dir}/util/src" />
+ <fileset dir="${aspectj.modules.dir}/weaver/src" />
+ </zip>
+ <build-eclipse-plugin name="${name.source}" />
+ </target>
+
+ <target name="do-ajde" depends="init-eclipse-plugins">
+ <property name="name.ajde" value="org.aspectj.ajde" />
+ <jar-property name="ep.aspectjtools.jar"
+ location="${aj.dist.dir}/tools/lib/aspectjtools.jar"
+ />
+ <clean-dir dir="${ep.eclipse.dist.dir}/${name.ajde}" />
+ <copy todir="${ep.eclipse.dist.dir}/${name.ajde}">
+ <fileset file="${ep.aspectjrt.jar}" />
+ <fileset file="${ep.aspectjtools.jar}" />
+ </copy>
+ <jar destfile="${ep.eclipse.dist.dir}/${name.ajde}/ajde.jar">
+ <zipfileset src="${ep.aspectjtools.jar}"
+ includes="org/aspectj/**"
+ />
+ <!-- TODO dangerous assumption: only org.aspectj? not org.eclipse or org.osgi? -->
+ </jar>
+ <build-eclipse-plugin name="${name.ajde}" />
+ </target>
+
+ <target name="do-doc" depends="init-eclipse-plugins">
+ <available property="ep.docs.available"
+ file="${aj.dist.dir}/docs/doc/examples/build.xml"
+ />
+ <fail unless="ep.docs.available"
+ message="no doc in ${aj.dist.dir}"
+ />
+ <property name="name.doc" value="org.aspectj.ajde.doc" />
+ <clean-dir dir="${ep.eclipse.dist.dir}/${name.doc}/doc" />
+ <copy todir="${ep.eclipse.dist.dir}/${name.doc}/doc">
+ <fileset dir="${aj.dist.dir}/docs/doc" />
+ </copy>
+ <build-eclipse-plugin name="${name.doc}" />
+ </target>
+
+ <macrodef name="build-eclipse-plugin">
+ <attribute name="name" />
+ <sequential>
+ <mkdir dir="${ep.eclipse.dist.dir}/@{name}" />
+ <copy todir="${ep.eclipse.dist.dir}/@{name}">
+ <fileset dir="${ep.dir}/@{name}" />
+ </copy>
+ <replace file="${ep.eclipse.dist.dir}/@{name}/plugin.xml"
+ token="build.version.eclipse.plugins"
+ value="${build.version.eclipse.plugins}"
+ />
+ <jar destfile="${ep.eclipse.dist.dir}/@{name}_${build.version.eclipse.plugins}.jar"
+ >
+ <fileset dir="${ep.eclipse.dist.dir}/@{name}" />
+ </jar>
+ </sequential>
+ </macrodef>
+
+</project> \ No newline at end of file