Add ant task for building the maven/ibiblio friendly binary and source jar files, and creating a .pom for them
git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@419060 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
611a6f2fdd
commit
d64e872005
48
build.xml
48
build.xml
@ -109,6 +109,7 @@
|
|||||||
<property name="apidocs.report.dir" location="${build.site}/apidocs"/>
|
<property name="apidocs.report.dir" location="${build.site}/apidocs"/>
|
||||||
<property name="changelog.file" location="${build.site}/changelog.html"/>
|
<property name="changelog.file" location="${build.site}/changelog.html"/>
|
||||||
<property name="dist.dir" location="build/dist"/>
|
<property name="dist.dir" location="build/dist"/>
|
||||||
|
<property name="mavendist.dir" location="build/maven-dist"/>
|
||||||
<property name="jar.name" value="poi"/>
|
<property name="jar.name" value="poi"/>
|
||||||
<property name="version.id" value="3.0-alpha2"/>
|
<property name="version.id" value="3.0-alpha2"/>
|
||||||
<property name="halt.on.test.failure" value="true"/>
|
<property name="halt.on.test.failure" value="true"/>
|
||||||
@ -216,6 +217,7 @@
|
|||||||
<mkdir dir="${jdepend.report.out.dir}"/>
|
<mkdir dir="${jdepend.report.out.dir}"/>
|
||||||
<mkdir dir="${apidocs.report.dir}"/>
|
<mkdir dir="${apidocs.report.dir}"/>
|
||||||
<mkdir dir="${dist.dir}"/>
|
<mkdir dir="${dist.dir}"/>
|
||||||
|
<mkdir dir="${mavendist.dir}"/>
|
||||||
<mkdir dir="${build.site.src}/${main.documentation}"/>
|
<mkdir dir="${build.site.src}/${main.documentation}"/>
|
||||||
|
|
||||||
<copy todir="${build.site.src}/${main.documentation}">
|
<copy todir="${build.site.src}/${main.documentation}">
|
||||||
@ -788,6 +790,52 @@ FORREST_HOME environment variable!</echo>
|
|||||||
description="Generates POI's website's contents"/>
|
description="Generates POI's website's contents"/>
|
||||||
|
|
||||||
|
|
||||||
|
<target name="maven-dist" depends="compile" description="Builds the jar files for a maven distribution, and the POM to go with them">
|
||||||
|
<!-- Build a Jar of all the class files -->
|
||||||
|
<jar destfile="${mavendist.dir}/${jar.name}-${version.id}.jar">
|
||||||
|
<manifest>
|
||||||
|
<attribute name="Built-By" value="${user.name}"/>
|
||||||
|
<section name="common">
|
||||||
|
<attribute name="Specification-Title" value="Jakarta POI"/>
|
||||||
|
<attribute name="Specification-Version" value="${version.id}-${DSTAMP}"/>
|
||||||
|
<attribute name="Specification-Vendor" value="Apache"/>
|
||||||
|
<attribute name="Implementation-Title" value="Jakarta POI"/>
|
||||||
|
<attribute name="Implementation-Version" value="${version.id}-${DSTAMP}"/>
|
||||||
|
<attribute name="Implementation-Vendor" value="Apache"/>
|
||||||
|
</section>
|
||||||
|
</manifest>
|
||||||
|
<fileset dir="${main.output.dir}" />
|
||||||
|
<fileset dir="${contrib.output.dir}" />
|
||||||
|
<fileset dir="${scratchpad.output.dir}" />
|
||||||
|
</jar>
|
||||||
|
|
||||||
|
<!-- Build a Jar file of all the source files -->
|
||||||
|
<jar destfile="${mavendist.dir}/${jar.name}-${version.id}-sources.jar">
|
||||||
|
<manifest>
|
||||||
|
<attribute name="Built-By" value="${user.name}"/>
|
||||||
|
<section name="common">
|
||||||
|
<attribute name="Specification-Title" value="Jakarta POI"/>
|
||||||
|
<attribute name="Specification-Version" value="${version.id}-${DSTAMP}"/>
|
||||||
|
<attribute name="Specification-Vendor" value="Apache"/>
|
||||||
|
<attribute name="Implementation-Title" value="Jakarta POI"/>
|
||||||
|
<attribute name="Implementation-Version" value="${version.id}-${DSTAMP}"/>
|
||||||
|
<attribute name="Implementation-Vendor" value="Apache"/>
|
||||||
|
</section>
|
||||||
|
</manifest>
|
||||||
|
<fileset dir="${main.src}" includes="**/*.java" />
|
||||||
|
<fileset dir="${contrib.src}" includes="**/*.java" />
|
||||||
|
<fileset dir="${scratchpad.src}" includes="**/*.java" />
|
||||||
|
</jar>
|
||||||
|
|
||||||
|
<!-- Build the pom -->
|
||||||
|
<!-- Copy from the base file, and substitute in the version -->
|
||||||
|
<filter token="VERSION" value="${version.id}" />
|
||||||
|
<copy
|
||||||
|
filtering="true"
|
||||||
|
file="poi.pom"
|
||||||
|
tofile="${mavendist.dir}/${jar.name}-${version.id}.pom"
|
||||||
|
/>
|
||||||
|
</target>
|
||||||
|
|
||||||
<target name="jar" depends="compile" description="Creates jar files for distribution">
|
<target name="jar" depends="compile" description="Creates jar files for distribution">
|
||||||
<jar basedir="${main.output.dir}" destfile="${dist.dir}/${jar.name}-${version.id}-${DSTAMP}.jar">
|
<jar basedir="${main.output.dir}" destfile="${dist.dir}/${jar.name}-${version.id}-${DSTAMP}.jar">
|
||||||
|
30
poi.pom
Normal file
30
poi.pom
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
<metadata>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<groupId>poi</groupId>
|
||||||
|
<artifactId>poi</artifactId>
|
||||||
|
<version>@VERSION@</version>
|
||||||
|
<packaging>jar</packaging>
|
||||||
|
<name>Jakarta POI</name>
|
||||||
|
<url>http://jakarta.apache.org/poi/</url>
|
||||||
|
<description>Jakarta POI - Java API To Access Microsoft Format Files</description>
|
||||||
|
|
||||||
|
<dependencies></dependencies>
|
||||||
|
|
||||||
|
<licenses>
|
||||||
|
<license>
|
||||||
|
<name>The Apache Software License, Version 2.0</name>
|
||||||
|
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
|
||||||
|
<distribution>repo</distribution>
|
||||||
|
</license>
|
||||||
|
</licenses>
|
||||||
|
<scm>
|
||||||
|
<url>http://svn.apache.org/viewvc/jakarta/poi/trunk</url>
|
||||||
|
<connection>scm:svn:http://svn.apache.org/repos/asf/jakarta/poi/trunk</connection>
|
||||||
|
</scm>
|
||||||
|
<issueTrackingUrl>http://issues.apache.org/bugzilla/</issueTrackingUrl>
|
||||||
|
<organization>
|
||||||
|
<name>Apache Software Foundation</name>
|
||||||
|
<url>http://www.apache.org/</url>
|
||||||
|
<logo>http://jakarta.apache.org/images/original-jakarta-logo.gif</logo>
|
||||||
|
</organization>
|
||||||
|
</metadata>
|
Loading…
Reference in New Issue
Block a user