annotate osgi-ant-bundlor.xml @ 33:f8b0dde24622

Replace groovy script with custom task to correct memory leak
author smith@nwoca.org
date Sat, 16 Apr 2011 16:27:53 -0400
parents a114600dc3d4
children 7df554d8c4c1
rev   line source
20
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
1 <?xml version="1.0" encoding="UTF-8"?>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
2 <project name="osgi-project-tasks" default="" basedir="."
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
3 xmlns:ssdtosgi="http://www.ssdt-ohio.org/ant/osgi"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
4 xmlns:ivy="antlib:fr.jayasoft.ivy.ant"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
5 xmlns:bundlor="antlib:com.springsource.bundlor.ant">
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
6
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
7 <description>Ant tasks to assist building OSGi bundles.</description>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
8
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
9 <target name="-init-osgi">
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
10 <ivy:settings file="ivysettings.xml"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
11 <ivy:cachepath resolveId="bundlor.classpath"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
12 pathid="bundlor.classpath"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
13 organisation="com.springsource.bundlor"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
14 module="com.springsource.bundlor.ant"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
15 revision="1.0.0.RELEASE"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
16 inline="true"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
17 type="jar"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
18 log="download-only"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
19 <taskdef resource="com/springsource/bundlor/ant/antlib.xml"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
20 uri="antlib:com.springsource.bundlor.ant"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
21 classpathref="bundlor.classpath"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
22
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
23 <macrodef name="jar"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
24 description="OSGi-ifies jar file"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
25 uri="http://www.ssdt-ohio.org/ant/osgi">
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
26 <attribute name="jar" description="input jar"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
27 <attribute name="symbolicName" description="Bundle Symbolic Name" default="${ivy.organisation}.${ivy.module}"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
28 <attribute name="name" description="Bundle Name" default="${application.title}"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
29 <attribute name="version" description="Bundle Version" default="${ivy.revision}"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
30 <attribute name="template" description="Bundle Template" default="${basedir}/template.mf"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
31 <sequential>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
32 <bundlor:bundlor
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
33 inputPath="${basedir}/@{jar}"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
34 outputPath="${basedir}/@{jar}"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
35 bundleVersion="@{version}"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
36 bundleSymbolicName="@{symbolicName}"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
37 failOnWarnings="true"
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
38 manifestTemplatePath="@{template}">
21
a114600dc3d4 CM-125: Fix reference to bundle name attribute
smith@nwoca.org
parents: 20
diff changeset
39 <property name="bundle.name" value="@{name}"/>
20
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
40 <propertyset>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
41 <propertyref prefix="ivy"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
42 <mapper type="glob" from="ivydeps." to="*"/>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
43 </propertyset>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
44 </bundlor:bundlor>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
45 </sequential>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
46 </macrodef>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
47
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
48 </target>
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
49
fe20e4ed4be2 CM-125: Ant script to assist creating OSGI jars.
smith@nwoca.org
parents:
diff changeset
50 </project>