comparison osgi-ant-bundlor.xml @ 36:82a5d5a000fe

CM-125: Auto connect osgi dependency to build process
author smith@nwoca.org
date Sat, 07 May 2011 11:22:58 -0400
parents 7df554d8c4c1
children ba7ae19e40a0
comparison
equal deleted inserted replaced
35:7df554d8c4c1 36:82a5d5a000fe
1 <?xml version="1.0" encoding="UTF-8"?> 1 <?xml version="1.0" encoding="UTF-8"?>
2 <project name="osgi-project-tasks" default="" basedir="." 2 <project name="osgi-project-tasks" default="" basedir="."
3 xmlns:ssdtosgi="http://www.ssdt-ohio.org/ant/osgi" 3 xmlns:ssdtosgi="http://www.ssdt-ohio.org/ant/osgi"
4 xmlns:ivy="antlib:fr.jayasoft.ivy.ant" 4 xmlns:ivy="antlib:fr.jayasoft.ivy.ant"
5 xmlns:bundlor="antlib:com.springsource.bundlor.ant"> 5 xmlns:bundlor="antlib:com.springsource.bundlor.ant"
6 xmlns:ssdtant="antlib:org.ssdt_ohio.tools.ant">
6 7
7 <description>Ant tasks to assist building OSGi bundles.</description> 8 <description>Ant tasks to assist building OSGi bundles.</description>
8 9
10 <ssdtant:add-dependency target="-post-jar" depends="-osgi-jar"/>
11
12 <target name="-osgi-jar" depends="-init-osgi,ivy-info">
13 <ssdtosgi:jar jar="${dist.jar}"/>
14 </target>
15
9 <target name="-init-osgi"> 16 <target name="-init-osgi">
10 <ivy:settings file="ivysettings.xml"/> 17 <ivy:settings file="ivysettings.xml"/>
11 <ivy:cachepath resolveId="bundlor.classpath" 18 <ivy:cachepath resolveId="bundlor.classpath"
12 pathid="bundlor.classpath" 19 pathid="bundlor.classpath"
13 organisation="com.springsource.bundlor" 20 organisation="com.springsource.bundlor"
27 <attribute name="symbolicName" description="Bundle Symbolic Name" default="${ivy.organisation}.${ivy.module}"/> 34 <attribute name="symbolicName" description="Bundle Symbolic Name" default="${ivy.organisation}.${ivy.module}"/>
28 <attribute name="name" description="Bundle Name" default="${application.title}"/> 35 <attribute name="name" description="Bundle Name" default="${application.title}"/>
29 <attribute name="version" description="Bundle Version" default="${ivy.revision}"/> 36 <attribute name="version" description="Bundle Version" default="${ivy.revision}"/>
30 <attribute name="template" description="Bundle Template" default="${basedir}/template.mf"/> 37 <attribute name="template" description="Bundle Template" default="${basedir}/template.mf"/>
31 <sequential> 38 <sequential>
39 <echo message="OSGI-ifying @{jar} as @{symbolicName};@{version}" level="info"/>
32 <bundlor:bundlor 40 <bundlor:bundlor
33 inputPath="${basedir}/@{jar}" 41 inputPath="${basedir}/@{jar}"
34 outputPath="${basedir}/@{jar}" 42 outputPath="${basedir}/@{jar}"
35 bundleVersion="@{version}" 43 bundleVersion="@{version}"
36 bundleSymbolicName="@{symbolicName}" 44 bundleSymbolicName="@{symbolicName}"