apache-commons-daemon/apache-commons-daemon-build.xml

99 lines
4.1 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<project name="commons-daemon" default="all" basedir=".">
<property file="build.properties" />
<property name="project.groupId" value="commons-daemon" />
<property name="project.artifactId" value="commons-daemon" />
<property name="project.version" value="1.3.4" />
<property name="compiler.source" value="1.8" />
<property name="compiler.target" value="${compiler.source}" />
<property name="build.finalName" value="${project.artifactId}-${project.version}" />
<property name="build.dir" value="target" />
<property name="build.outputDir" value="${build.dir}/classes" />
<property name="build.srcDir" value="src/main/java" />
<property name="build.resourceDir" value="src/main/resources" />
<property name="reporting.outputDirectory" value="${build.dir}/site" />
<target name="clean" description="Clean the output directory">
<delete dir="${build.dir}" />
</target>
<target name="compile" description="Compile the code">
<mkdir dir="${build.outputDir}" />
<javac
destdir="${build.outputDir}"
nowarn="false"
debug="true"
optimize="false"
deprecation="true"
target="${compiler.target}"
verbose="false"
fork="false"
source="${compiler.source}">
<src>
<pathelement location="${build.srcDir}" />
</src>
</javac>
</target>
<target name="javadoc" description="Generates the Javadoc of the application">
<javadoc
sourcepath="${build.srcDir}"
packagenames="*"
destdir="${reporting.outputDirectory}/apidocs"
access="protected"
source="${compiler.source}"
verbose="false"
version="true"
use="true"
author="true"
splitindex="false"
nodeprecated="false"
nodeprecatedlist="false"
notree="false"
noindex="false"
nohelp="false"
nonavbar="false"
serialwarn="false"
charset="ISO-8859-1"
linksource="false"
breakiterator="false" />
</target>
<target name="package" depends="compile" description="Package the application">
<jar
jarfile="${build.dir}/${build.finalName}.jar"
compress="true"
index="false"
basedir="${build.outputDir}"
excludes="**/package.html">
<manifest>
<attribute name="Bundle-DocURL" value="https://commons.apache.org/proper/commons-daemon/"/>
<attribute name="Bundle-License" value="https://www.apache.org/licenses/LICENSE-2.0.txt"/>
<attribute name="Bundle-ManifestVersion" value="2"/>
<attribute name="Bundle-Name" value="Apache Commons Daemon"/>
<attribute name="Bundle-SymbolicName" value="org.apache.commons.commons-daemon"/>
<attribute name="Bundle-Vendor" value="The Apache Software Foundation"/>
<attribute name="Bundle-Version" value="${project.version}"/>
<attribute name="Export-Package" value="org.apache.commons.daemon;version=&quot;${project.version}&quot;,org.apache.commons.daemon.support;version=&quot;${project.version}&quot;"/>
<attribute name="Implementation-Title" value="Apache Commons Daemon"/>
<attribute name="Implementation-Vendor-Id" value="org.apache"/>
<attribute name="Implementation-Vendor" value="The Apache Software Foundation"/>
<attribute name="Implementation-Version" value="${project.version}"/>
<attribute name="Require-Capability" value="osgi.ee;filter:=&quot;(&amp;(osgi.ee=JavaSE)(version=${compiler.target}))&quot;"/>
<attribute name="Specification-Title" value="Apache Commons Daemon"/>
<attribute name="Specification-Vendor" value="The Apache Software Foundation"/>
<attribute name="Specification-Version" value="${project.version}"/>
<attribute name="X-Compile-Source-JDK" value="${compiler.source}"/>
<attribute name="X-Compile-Target-JDK" value="${compiler.target}"/>
</manifest>
</jar>
</target>
<target name="all" depends="package,javadoc" description="Build the project" />
</project>