Stuart McCulloch | 0d71077 | 2008-02-19 08:34:01 +0000 | [diff] [blame] | 1 | <?xml version="1.0" encoding="UTF-8"?> |
Stuart McCulloch | 3be101e | 2011-06-16 17:33:04 +0000 | [diff] [blame] | 2 | <!-- |
| 3 | Licensed to the Apache Software Foundation (ASF) under one |
| 4 | or more contributor license agreements. See the NOTICE file |
| 5 | distributed with this work for additional information |
| 6 | regarding copyright ownership. The ASF licenses this file |
| 7 | to you under the Apache License, Version 2.0 (the |
| 8 | "License"); you may not use this file except in compliance |
| 9 | with the License. You may obtain a copy of the License at |
| 10 | |
| 11 | http://www.apache.org/licenses/LICENSE-2.0 |
| 12 | |
| 13 | Unless required by applicable law or agreed to in writing, |
| 14 | software distributed under the License is distributed on an |
| 15 | "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 16 | KIND, either express or implied. See the License for the |
| 17 | specific language governing permissions and limitations |
| 18 | under the License. |
| 19 | --> |
Stuart McCulloch | 0d71077 | 2008-02-19 08:34:01 +0000 | [diff] [blame] | 20 | |
| 21 | <!-- ====================================================================== --> |
| 22 | <!-- Ant build file (http://ant.apache.org/) for Ant 1.6.2 or above. --> |
| 23 | <!-- ====================================================================== --> |
| 24 | |
| 25 | <project name="ARTIFACT_ID" default="package" basedir="."> |
| 26 | |
| 27 | <!-- ====================================================================== --> |
| 28 | <!-- Import maven-build.xml into the current project --> |
| 29 | <!-- ====================================================================== --> |
| 30 | |
| 31 | <import file="maven-build.xml"/> |
| 32 | |
| 33 | <!-- ====================================================================== --> |
| 34 | <!-- Help target --> |
| 35 | <!-- ====================================================================== --> |
| 36 | |
| 37 | <target name="help"> |
| 38 | <echo message="Please run: $ant -projecthelp"/> |
| 39 | </target> |
| 40 | |
Stuart McCulloch | 37ec4e6 | 2008-05-16 04:39:32 +0000 | [diff] [blame] | 41 | <property name="bnd.version" value="BND_VERSION"/> |
Stuart McCulloch | 0d71077 | 2008-02-19 08:34:01 +0000 | [diff] [blame] | 42 | |
| 43 | <target name="get-bnd" |
| 44 | depends="test-offline" |
| 45 | description="Download BND tool" |
| 46 | unless="maven.mode.offline"> |
| 47 | <mkdir dir="${maven.repo.local}"/> |
| 48 | <mkdir dir="${maven.repo.local}/biz/aQute/bnd/${bnd.version}"/> |
| 49 | <get src="http://www.aqute.biz/repo/biz/aQute/bnd/${bnd.version}/bnd-${bnd.version}.jar" |
| 50 | dest="${maven.repo.local}/biz/aQute/bnd/${bnd.version}/bnd-${bnd.version}.jar" |
| 51 | usetimestamp="true" |
| 52 | ignoreerrors="true"/> |
| 53 | </target> |
| 54 | |
Stuart McCulloch | 0d71077 | 2008-02-19 08:34:01 +0000 | [diff] [blame] | 55 | <target name="package" depends="compile,test,get-bnd" description="Package the bundle"> |
Stuart McCulloch | 37ec4e6 | 2008-05-16 04:39:32 +0000 | [diff] [blame] | 56 | <taskdef resource="aQute/bnd/ant/taskdef.properties"> |
| 57 | <classpath> |
| 58 | <pathelement location="${maven.repo.local}/biz/aQute/bnd/${bnd.version}/bnd-${bnd.version}.jar"/> |
| 59 | </classpath> |
| 60 | </taskdef> |
Stuart McCulloch | 0d71077 | 2008-02-19 08:34:01 +0000 | [diff] [blame] | 61 | <pathconvert property="bnd.classpath" refid="build.classpath" pathsep=","/> |
Stuart McCulloch | ee51abf | 2008-02-19 09:49:41 +0000 | [diff] [blame] | 62 | <bnd files="maven-build.bnd" classpath="${maven.build.outputDir},${bnd.classpath}"/> |
Stuart McCulloch | 0d71077 | 2008-02-19 08:34:01 +0000 | [diff] [blame] | 63 | </target> |
| 64 | |
| 65 | </project> |