cdi-api/cdi-api-build.xml

136 lines
7.3 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<project name="cdi-api" default="package" basedir=".">
<!-- ====================================================================== -->
<!-- Build environment properties -->
<!-- ====================================================================== -->
<property file="build.properties"/>
<property name="project.groupId" value="jakarta.enterprise"/>
<property name="project.artifactId" value="jakarta.enterprise.cdi-api"/>
<property name="project.version" value="2.0.2"/>
<property name="project.name" value="Jakarta CDI"/>
<property name="project.description" value="APIs for Jakarta CDI (Contexts and Dependency Injection)"/>
<property name="project.license.url" value="https://repository.jboss.org/licenses/apache-2.0.txt"/>
<property name="project.organization.name" value="Eclipse Foundation"/>
<property name="project.organization.url" value="https://jakarta.ee"/>
<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"/>
<!-- ====================================================================== -->
<!-- Defining classpaths -->
<!-- ====================================================================== -->
<path id="build.classpath">
<fileset dir="lib">
<include name="**/*"/>
</fileset>
</path>
<!-- ====================================================================== -->
<!-- Cleaning up target -->
<!-- ====================================================================== -->
<target name="clean" description="Clean the output directory">
<delete dir="${build.dir}"/>
</target>
<!-- ====================================================================== -->
<!-- Compilation 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>
<classpath refid="build.classpath"/>
</javac>
<copy todir="${build.outputDir}">
<fileset dir="${build.resourceDir}"/>
</copy>
</target>
<!-- ====================================================================== -->
<!-- Javadoc target -->
<!-- ====================================================================== -->
<target name="javadoc" description="Generates the Javadoc of the application">
<javadoc sourcepath="${build.srcDir}"
packagenames="*"
destdir="${reporting.outputDirectory}/apidocs"
access="protected"
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"
source="${compiler.source}"
classpathref="build.classpath"/>
</target>
<!-- ====================================================================== -->
<!-- Package 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-Description" value="${project.description}"/>
<attribute name="Bundle-DocURL" value="${project.organization.url}"/>
<attribute name="Bundle-License" value="${project.license.url}"/>
<attribute name="Bundle-ManifestVersion" value="2"/>
<attribute name="Bundle-Name" value="${project.name}"/>
<attribute name="Bundle-SymbolicName" value="${project.artifactId}"/>
<attribute name="Bundle-Vendor" value="${project.organization.name}"/>
<attribute name="Bundle-Version" value="${project.version}"/>
<attribute name="Export-Package" value="javax.decorator;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.inject&quot;,javax.enterprise.context.control;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.context,javax.interceptor&quot;,javax.enterprise.context.spi;version=&quot;2.0&quot;,javax.enterprise.context;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.util,javax.inject&quot;,javax.enterprise.event;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.util&quot;,javax.enterprise.inject.literal;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.util,javax.inject&quot;,javax.enterprise.inject.se;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.inject,javax.enterprise.inject.spi&quot;,javax.enterprise.inject.spi.configurator;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.context.spi,javax.enterprise.event,javax.enterprise.inject,javax.enterprise.inject.spi,javax.enterprise.util&quot;,javax.enterprise.inject.spi;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.context.spi,javax.enterprise.event,javax.enterprise.inject,javax.enterprise.inject.spi.configurator,javax.interceptor&quot;,javax.enterprise.inject;version=&quot;2.0&quot;;uses:=&quot;javax.enterprise.context,javax.enterprise.util,javax.inject&quot;,javax.enterprise.util;version=&quot;2.0&quot;"/>
<attribute name="Import-Package" value="javax.enterprise.context.spi;version=&quot;[2.0,3)&quot;,javax.enterprise.context;version=&quot;[2.0,3)&quot;,javax.enterprise.event;version=&quot;[2.0,3)&quot;,javax.enterprise.inject.spi.configurator;version=&quot;[2.0,3)&quot;,javax.enterprise.inject.spi;version=&quot;[2.0,3)&quot;,javax.enterprise.inject;version=&quot;[2.0,3)&quot;,javax.enterprise.util;version=&quot;[2.0,3)&quot;,javax.inject,javax.interceptor;version=&quot;[1.2,2)&quot;"/>
<attribute name="Require-Capability" value="osgi.ee;filter:=&quot;(&amp;(osgi.ee=JavaSE)(version=${compiler.target}))&quot;"/>
</manifest>
</jar>
</target>
<!-- ====================================================================== -->
<!-- A dummy target for the package named after the type it creates -->
<!-- ====================================================================== -->
<target name="jar" depends="package" description="Builds the jar for the application"/>
</project>