|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | + |
| 3 | +<project name="commons-collections4" default="package" basedir="."> |
| 4 | + |
| 5 | + <!-- ====================================================================== --> |
| 6 | + <!-- Build environment properties --> |
| 7 | + <!-- ====================================================================== --> |
| 8 | + |
| 9 | + <property file="build.properties"/> |
| 10 | + <property name="project.groupId" value="org.apache.commons"/> |
| 11 | + <property name="project.artifactId" value="commons-collections4"/> |
| 12 | + <property name="project.version" value="4.4"/> |
| 13 | + <property name="bundle.version" value="${project.version}.0"/> |
| 14 | + |
| 15 | + <property name="compiler.release" value="8"/> |
| 16 | + <property name="compiler.source" value="1.${compiler.release}"/> |
| 17 | + <property name="compiler.target" value="${compiler.source}"/> |
| 18 | + |
| 19 | + <property name="build.finalName" value="${project.artifactId}-${project.version}"/> |
| 20 | + <property name="build.dir" value="target"/> |
| 21 | + <property name="build.outputDir" value="${build.dir}/classes"/> |
| 22 | + <property name="build.srcDir" value="src/main/java"/> |
| 23 | + <property name="build.resourceDir" value="."/> |
| 24 | + |
| 25 | + <property name="reporting.outputDirectory" value="${build.dir}/site"/> |
| 26 | + |
| 27 | + <!-- ====================================================================== --> |
| 28 | + <!-- Defining classpaths --> |
| 29 | + <!-- ====================================================================== --> |
| 30 | + |
| 31 | + <path id="build.classpath"/> |
| 32 | + |
| 33 | + <!-- ====================================================================== --> |
| 34 | + <!-- Cleaning up target --> |
| 35 | + <!-- ====================================================================== --> |
| 36 | + |
| 37 | + <target name="clean" description="Clean the output directory"> |
| 38 | + <delete dir="${build.dir}"/> |
| 39 | + </target> |
| 40 | + |
| 41 | + <!-- ====================================================================== --> |
| 42 | + <!-- Compilation target --> |
| 43 | + <!-- ====================================================================== --> |
| 44 | + |
| 45 | + <target name="compile" description="Compile the code"> |
| 46 | + <mkdir dir="${build.outputDir}"/> |
| 47 | + <javac destdir="${build.outputDir}" |
| 48 | + encoding="iso-8859-1" |
| 49 | + nowarn="false" |
| 50 | + debug="true" |
| 51 | + optimize="false" |
| 52 | + deprecation="true" |
| 53 | + release="${compiler.release}" |
| 54 | + target="${compiler.target}" |
| 55 | + verbose="false" |
| 56 | + fork="false" |
| 57 | + source="${compiler.source}"> |
| 58 | + <src> |
| 59 | + <pathelement location="${build.srcDir}"/> |
| 60 | + </src> |
| 61 | + <classpath refid="build.classpath"/> |
| 62 | + </javac> |
| 63 | + <mkdir dir="${build.outputDir}/META-INF"/> |
| 64 | + <copy todir="${build.outputDir}/META-INF"> |
| 65 | + <fileset dir="${build.resourceDir}"> |
| 66 | + <include name="NOTICE.txt"/> |
| 67 | + <include name="LICENSE.txt"/> |
| 68 | + <include name="NOTICE"/> |
| 69 | + <include name="LICENSE"/> |
| 70 | + </fileset> |
| 71 | + </copy> |
| 72 | + </target> |
| 73 | + |
| 74 | + <!-- ====================================================================== --> |
| 75 | + <!-- Javadoc target --> |
| 76 | + <!-- ====================================================================== --> |
| 77 | + |
| 78 | + <target name="javadoc" description="Generates the Javadoc of the application"> |
| 79 | + <javadoc sourcepath="${build.srcDir}" |
| 80 | + packagenames="*" |
| 81 | + destdir="${reporting.outputDirectory}/apidocs" |
| 82 | + access="protected" |
| 83 | + verbose="false" |
| 84 | + encoding="iso-8859-1" |
| 85 | + version="true" |
| 86 | + use="true" |
| 87 | + author="true" |
| 88 | + splitindex="false" |
| 89 | + nodeprecated="false" |
| 90 | + nodeprecatedlist="false" |
| 91 | + notree="false" |
| 92 | + noindex="false" |
| 93 | + nohelp="false" |
| 94 | + nonavbar="false" |
| 95 | + serialwarn="false" |
| 96 | + source="${compiler.source}" |
| 97 | + linksource="true" |
| 98 | + breakiterator="false"> |
| 99 | + </javadoc> |
| 100 | + </target> |
| 101 | + |
| 102 | + <!-- ====================================================================== --> |
| 103 | + <!-- Package target --> |
| 104 | + <!-- ====================================================================== --> |
| 105 | + |
| 106 | + <target name="package" depends="compile" description="Package the application"> |
| 107 | + <jar jarfile="${build.dir}/${build.finalName}.jar" |
| 108 | + compress="true" |
| 109 | + index="false" |
| 110 | + basedir="${build.outputDir}" |
| 111 | + excludes="**/package.html"> |
| 112 | + <manifest> |
| 113 | + <attribute name="Automatic-Module-Name" value="org.apache.commons.collections4"/> |
| 114 | + <attribute name="Bundle-Description" value="The Apache Commons Collections package contains types that extend and augment the Java Collections Framework."/> |
| 115 | + <attribute name="Bundle-DocURL" value="https://commons.apache.org/proper/commons-collections/"/> |
| 116 | + <attribute name="Bundle-License" value="https://www.apache.org/licenses/LICENSE-2.0.txt"/> |
| 117 | + <attribute name="Bundle-ManifestVersion" value="2"/> |
| 118 | + <attribute name="Bundle-Name" value="Apache Commons Collections"/> |
| 119 | + <attribute name="Bundle-SymbolicName" value="${project.groupId}.${project.artifactId}"/> |
| 120 | + <attribute name="Bundle-Vendor" value="The Apache Software Foundation"/> |
| 121 | + <attribute name="Bundle-Version" value="${bundle.version}"/> |
| 122 | + <attribute name="Export-Package" value="org.apache.commons.collections4.bag;version="${project.version}",org.apache.commons.collections4.bidimap;version="${project.version}",org.apache.commons.collections4.collection;version="${project.version}",org.apache.commons.collections4.comparators;version="${project.version}",org.apache.commons.collections4.functors;version="${project.version}",org.apache.commons.collections4.iterators;version="${project.version}",org.apache.commons.collections4.keyvalue;version="${project.version}",org.apache.commons.collections4.list;version="${project.version}",org.apache.commons.collections4.map;version="${project.version}",org.apache.commons.collections4.multimap;version="${project.version}",org.apache.commons.collections4.multiset;version="${project.version}",org.apache.commons.collections4.properties;version="${project.version}",org.apache.commons.collections4.queue;version="${project.version}",org.apache.commons.collections4.sequence;version="${project.version}",org.apache.commons.collections4.set;version="${project.version}",org.apache.commons.collections4.splitmap;version="${project.version}",org.apache.commons.collections4.trie.analyzer;version="${project.version}",org.apache.commons.collections4.trie;version="${project.version}",org.apache.commons.collections4;version="${project.version}""/> |
| 123 | + <attribute name="Implementation-Title" value="Apache Commons Collections"/> |
| 124 | + <attribute name="Implementation-Vendor" value="The Apache Software Foundation"/> |
| 125 | + <attribute name="Implementation-Version" value="${project.version}"/> |
| 126 | + <attribute name="Import-Package" value="org.w3c.dom"/> |
| 127 | + <attribute name="Include-Resource" value="META-INF/LICENSE.txt=LICENSE.txt,META-INF/NOTICE.txt=NOTICE.txt"/> |
| 128 | + <attribute name="Require-Capability" value="osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=${compiler.target}))""/> |
| 129 | + <attribute name="Specification-Title" value="Apache Commons Collections"/> |
| 130 | + <attribute name="Specification-Vendor" value="The Apache Software Foundation"/> |
| 131 | + <attribute name="Specification-Version" value="${project.version}"/> |
| 132 | + </manifest> |
| 133 | + </jar> |
| 134 | + </target> |
| 135 | + |
| 136 | + <!-- ====================================================================== --> |
| 137 | + <!-- A dummy target for the package named after the type it creates --> |
| 138 | + <!-- ====================================================================== --> |
| 139 | + |
| 140 | + <target name="jar" depends="package" description="Builds the jar for the application"/> |
| 141 | + |
| 142 | +</project> |
0 commit comments