build.xml revision 1514
643a14a5271ed19ec30a9882d4b9e9ae1c357fb1Lennart Poettering ! CDDL HEADER START
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! The contents of this file are subject to the terms of the
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers ! Common Development and Distribution License, Version 1.0 only
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers ! (the "License"). You may not use this file except in compliance
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! with the License.
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering ! You can obtain a copy of the license at
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering ! trunk/opends/resource/legal-notices/OpenDS.LICENSE
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! or https://OpenDS.dev.java.net/OpenDS.LICENSE.
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! See the License for the specific language governing permissions
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! and limitations under the License.
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! When distributing Covered Code, include this CDDL HEADER in each
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering ! file and include the License file at
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
5430f7f2bc7330f3088b894166bf3524a067e3d8Lennart Poettering ! add the following below this CDDL HEADER, with the fields enclosed
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! by brackets "[]" replaced with your own identifying information:
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering ! Portions Copyright [yyyy] [name of copyright owner]
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers ! CDDL HEADER END
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers ! Portions Copyright 2006-2007 Sun Microsystems, Inc.
20bbd54f603994a3cc211d2795de16550882ed8dKay Sievers<project name="Directory Server" basedir="." default="package">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <description>
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers This is the build script for the OpenDS Directory Server. See the BUILDING
b30b4260255702345eab1ac076bb00869057c16bKay Sievers file in this directory for build instructions.
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers </description>
e88dcb8f774314ff4d56f8e33773af2f6bfc9d18Lennart Poettering <!-- General server-wide properties -->
e88dcb8f774314ff4d56f8e33773af2f6bfc9d18Lennart Poettering <property name="src.dir" location="src/server" />
e88dcb8f774314ff4d56f8e33773af2f6bfc9d18Lennart Poettering <property name="build.dir" location="build" />
74b91131ed09850ed487a2f7849147ff6f80194dLennart Poettering <property name="classes.dir" location="${build.dir}/classes" />
114a50f898a89bd7784c215ac5df95ec8c45a905Lennart Poettering <property name="lib.dir" location="lib" />
9262a519468491c80df2998eda238e2ac86a810dLennart Poettering <property name="ext.dir" location="ext" />
114a50f898a89bd7784c215ac5df95ec8c45a905Lennart Poettering <property name="package.dir" location="${build.dir}/package" />
114a50f898a89bd7784c215ac5df95ec8c45a905Lennart Poettering <property name="javadoc.dir" location="${build.dir}/javadoc" />
4b2d99d9f4258a29f0bf8b1a78d17836e75bc378Lennart Poettering <property name="resource.dir" location="resource" />
e88dcb8f774314ff4d56f8e33773af2f6bfc9d18Lennart Poettering <property name="scripts.dir" location="${resource.dir}/bin" />
4b2d99d9f4258a29f0bf8b1a78d17836e75bc378Lennart Poettering <property name="config.dir" location="${resource.dir}/config" />
4b2d99d9f4258a29f0bf8b1a78d17836e75bc378Lennart Poettering <property name="build.debuglevel" value="lines,vars,source" />
e88dcb8f774314ff4d56f8e33773af2f6bfc9d18Lennart Poettering <!-- Properties for build tools -->
e88dcb8f774314ff4d56f8e33773af2f6bfc9d18Lennart Poettering <property name="buildtools.src.dir" location="src/build-tools" />
4b2d99d9f4258a29f0bf8b1a78d17836e75bc378Lennart Poettering <property name="buildtools.classes.dir" location="${build.dir}/build-tools/classes" />
d122948d6fbaac4505cf14a08f1237daa89efdd0Lennart Poettering <!-- Properties for use in unit testing. -->
d122948d6fbaac4505cf14a08f1237daa89efdd0Lennart Poettering <property name="unittest.testng.dir" location="tests/unit-tests-testng"/>
d122948d6fbaac4505cf14a08f1237daa89efdd0Lennart Poettering location="${unittest.testng.dir}/src/server"/>
02f130cbd943c5c177cb0e711db0447cac685d67Lennart Poettering location="${build.dir}/unit-tests/classes" />
5a1e99375d03bc88795d68c66bf3933dd04c1015Lennart Poettering location="${build.dir}/unit-tests/report"/>
036643a247c659db8e1b3df1778d51553a816ec9Lennart Poettering location="${build.dir}/unit-tests/resource"/>
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering <!-- Properties for use in functional/integration testing. -->
8e8eb8fbafcaa841fa5393e396acde27b26edf2fKay Sievers location="${functest.testng.dir}/src"/>
8ece4cab426cce6759ff240504dc876502f4c483Kay Sievers <!-- Properties for use with the DSML component. -->
8ece4cab426cce6759ff240504dc876502f4c483Kay Sievers <property name="dsml.dir" location="resource/dsml" />
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <property name="dsml.src.dir" location="src/dsml" />
8ece4cab426cce6759ff240504dc876502f4c483Kay Sievers <property name="dsml.lib.dir" location="${dsml.dir}/lib" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <property name="dsml.gen.dir" location="${build.dir}/dsml/gen" />
8e8eb8fbafcaa841fa5393e396acde27b26edf2fKay Sievers <property name="dsml.classes.dir" location="${build.dir}/dsml/classes" />
8c4a3079a7f358c179430d1aec59de8b670b5f6eLennart Poettering <!-- Properties for use with the Quick Setup. -->
8c4a3079a7f358c179430d1aec59de8b670b5f6eLennart Poettering <property name="quicksetup.src.dir" location="src/quicksetup" />
b8079ae19b41c9b61850c796dddc601b826850e0Kay Sievers location="${build.dir}/quicksetup/classes" />
b8079ae19b41c9b61850c796dddc601b826850e0Kay Sievers <property name="ads.src.dir" location="src/ads" />
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers <!-- Properties for use with the Status Panel. -->
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers <property name="statuspanel.src.dir" location="src/statuspanel" />
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers location="${build.dir}/statuspanel/classes" />
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers <!-- Properties for coverage diff reports -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <property name="cvgdiff.dir" location="build/diff" />
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers location="${cvgdiff.dir}/report" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Properties for code coverage testing. -->
0237edf7d24a53792122ec1c8225babf2ad3e227Kay Sievers <property name="coverage.dir" location="build/coverage" />
131a4dcfd4375f235a1f512339c0909e8bcc730bKay Sievers location="${coverage.dir}/reports/unit" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers location="${coverage.dir}/instrumentedcode" />
ac7019f33f1618f5b69ed44a8623e2596f1e3856Lennart Poettering location="${coverage.dir}/gathereddata" />
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <!-- Properties for the EMMA code coverage tool. -->
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <property name="emma.dir" location="${ext.dir}/emma/lib" />
9b80f05fb727edc70a305d912ab6cf1c3bdbf67eKay Sievers <!-- Properties for the AspectJ tools -->
9b80f05fb727edc70a305d912ab6cf1c3bdbf67eKay Sievers <property name="aj.dir" location="${ext.dir}/aspectj" />
6b8b149a215ba49f96907aedd01a42f3fcdb95baKay Sievers <property name="aj.lib.dir" location="${aj.dir}/lib" />
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers <!-- Properties for the TestNG unit testing tool. -->
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <property name="testng.dir" location="${ext.dir}/testng" />
d3f09cf39637de2441288b5e4c93eecbd1fb872dKay Sievers <property name="testng.lib.dir" location="${testng.dir}/lib" />
487393e9f11e4a06d91df03232914bd8c4b3368eLennart Poettering <!-- Properties for the ANT build tool. -->
036643a247c659db8e1b3df1778d51553a816ec9Lennart Poettering <property name="ant.dir" location="${ext.dir}/ant" />
70fcff314feff469a8e61dbe5017ed74f5e0a09dLennart Poettering <property name="ant.lib.dir" location="${ant.dir}/lib" />
061978fa4d10851d18786432688a32984732c376Lennart Poettering <!-- Properties for the checkstyle tool. -->
af2d49f70bcff20efaf2d69aecaf4b3e898ff1faLennart Poettering <property name="checkstyle.dir" location="${ext.dir}/checkstyle" />
af2d49f70bcff20efaf2d69aecaf4b3e898ff1faLennart Poettering <property name="checkstyle.cache.dir" location=".checkstyle-cache" />
91901329245f070b621a24577393fb8f4ce9bffcLennart Poettering <!-- Properties for the SVNKit tool. -->
05d02d8db0b3a7fd7634f7a0bd35ad96da469fb4Lennart Poettering <property name="svnkit.dir" location="${ext.dir}/svnkit" />
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <!-- Properties for Directory Server version information. -->
501fc174c22aebd3181af08a4cfa65cc92bbe233Lennart Poettering location="${src.dir}/org/opends/server/util/DynamicConstants.java" />
b8079ae19b41c9b61850c796dddc601b826850e0Kay Sievers location="${resource.dir}/DynamicConstants.java.stubs" />
af2d49f70bcff20efaf2d69aecaf4b3e898ff1faLennart Poettering <!-- Properties for administration framework code generation. -->
83cc030fadf71d63d488cf9015275f9e5a02e2ccLennart Poettering <property name="admin.defn.dir" location="src/admin/defn" />
ddcbc8737873ca1904562d7d3ca3de9946e2f889Matthias Clasen <property name="admin.src.dir" location="src/admin/generated" />
baa5ad26fd5da7bc3d7253904ac30112c94a64c2Kay Sievers <property name="admin.rules.dir" location="resource/admin" />
e5e83e8362e946890ac991fc86a2c5869f9befdfLennart Poettering <!-- Create a package bundle containing the DSML library. -->
86aa7ba4f9969bbfc75ebd51f944313695f1a0a1Lennart Poettering description="Build a Directory Server package bundle with DSML.">
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <!-- The build target that should be used before committing code. -->
eb2e280f9c59b66965c9316eadc4c113a13ca744Lucas De Marchi <target name="precommit" depends="checkstyle,clean,checkprecommit,dsml,testwithcoverage"
9e7adc3ae1133fa08a468768a490812299fad030Lucas De Marchi description="Perform all processing needed before committing code.">
9841e8e3d305e6f4173c9aedbe8d57adfe10d145Gustavo Sverzut Barbieri <!-- The build target that should be used for nightly builds. -->
9841e8e3d305e6f4173c9aedbe8d57adfe10d145Gustavo Sverzut Barbieri depends="checkstyle,dsml,srczip,javadoc,coverage,testallwithcoverage"
c226fa4196aacf44a2aa9ebbd222161f79c2f070Lucas De Marchi description="Perform all processing needed for nightly builds.">
f5c88ec1330b61787441156de7d764a140774bd2Miklos Vajna <!-- The build target that should be used for weekly builds. -->
f5c88ec1330b61787441156de7d764a140774bd2Miklos Vajna description="Perform all processing needed for weekly builds.">
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov <!-- The build target that should be used to build everything. -->
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov depends="checkstyle,clean,checkprecommit,dsml,srczip,javadoc,testallwithcoverage"
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov description="Build using all defined targets.">
54e4fdef80693f7fd7893bd048bb4d9a258b03a6Chris E Ferron <!-- Remove all dynamically-generated build files. -->
1bd8b8184ee3bc7fc023d6d6dfb2ca99fb6612f3Koen Kooi description="Clean up any files generated during the build process">
6fdae8a6a40d6a3b5f77516abaee23b3eab002f6Dexter Morgan <!-- Perform common initialization common to several targets after cleaning out the previous build environment. -->
6fdae8a6a40d6a3b5f77516abaee23b3eab002f6Dexter Morgan <target name="cleaninit" depends="clean,init">
c226fa4196aacf44a2aa9ebbd222161f79c2f070Lucas De Marchi <!-- Set the property valid.java.version if the java version is valid. -->
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov depends="buildtools" >
1bd8b8184ee3bc7fc023d6d6dfb2ca99fb6612f3Koen Kooi <property name="min.java.version" value="1.5.0_08" />
8c4a3079a7f358c179430d1aec59de8b670b5f6eLennart Poettering classname="org.opends.build.tools.ValidJavaVersion" >
8c4a3079a7f358c179430d1aec59de8b670b5f6eLennart Poettering <condition property="valid.java.version">
a8f11321c209830a35edd0357e8def5d4437d854Lennart Poettering <validjavaversion minVersion="${min.java.version}" />
27b5482cc08b7fac1b6b15d980d42ae04f3ae1caLennart Poettering <!-- Warn if the build java version is too old. -->
f695b3b09b672c327c5b525ed7a2390c4b99a67eLennart Poettering depends="validjavaversion"
8c4a3079a7f358c179430d1aec59de8b670b5f6eLennart Poettering message="WARNING: Java version ${java.version} is too old."/>
0b7964b804e093d31c9adc34ba1917017c7f4d60Lennart Poettering message="Java version ${min.java.version} or later is required to build OpenDS."/>
5192bd1945f59254b3d260ded15dd9f2b8cc2de7Lennart Poettering <!-- Perform common initialization common to several targets. -->
22be093ffb403a1c474037939ca9b88b1ee39f77Lennart Poettering <pathelement location="${classes.dir}" />
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <format property="timestamp" pattern="yyyyMMddHHmmss'Z'"
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering timezone="UTC" />
6b1dc2bd3cdb3bd932b0692be636ddd2879edb92Lennart Poettering <condition property="DEBUG_BUILD" value="false">
42bb3074fe9632d7aa0fee825ad30d2083c3c629Ran Benita </condition>
42bb3074fe9632d7aa0fee825ad30d2083c3c629Ran Benita <condition property="WEAVE_ENABLED" value="false">
70fcff314feff469a8e61dbe5017ed74f5e0a09dLennart Poettering ! For some reason, some Apple VMs put quotes around the value of the
f057408c9c3b54b6eeb96cd9f0a1333f30610614Lennart Poettering ! java.vm.vendor property, which wreaks havoc with DynamicConstants. This
de47ca9b50e8c05c9fc116ff37794e526bddf92eLennart Poettering ! pair of conditions attempts to work around that by detecting the quote
f92a18f5274ad506aed600b2ed8f4a560c510807Lennart Poettering ! and surrounding the value with backslashes.
5e6afdd3d359fc42de7ac432243e98673577e81fLennart Poettering <condition property="JVM_VENDOR" value="Apple Computer">
85ed27f699939f75b8422ae67e016bdf9f439da9Lennart Poettering <contains string="${java.vm.vendor}" substring="Apple Computer"
70449379def39da2a3efbd7c7da27a4745702b08Lennart Poettering casesensitive="false" />
baa5ad26fd5da7bc3d7253904ac30112c94a64c2Kay Sievers </condition>
baa5ad26fd5da7bc3d7253904ac30112c94a64c2Kay Sievers <condition property="JVM_VENDOR" value="${java.vm.vendor}">
f0b02ca2afa806efb73b43a81204ff21c4c65446Lennart Poettering <!-- Build the DynamicConstants.java file and any of its dependencies. -->
4466194c43a25bc51b21226f04245131e698bb3fLennart Poettering <target name="dynamicconstants" depends="init,buildtools">
70449379def39da2a3efbd7c7da27a4745702b08Lennart Poettering <!-- Get the revision number of the current Subversion workspace -->
4e67ddd6b39c2847cc399ab0874427baa7ea8935Lennart Poettering classname="org.opends.build.tools.GetSubversionRevision">
d6bca18e28268485619127024fd944b8497798a7Bill Nottingham <getsvnrevision property="REVISION_NUMBER" />
623ac9d2fce3170125ead9be20f56bfe68ea125eKay Sievers <!-- Construct the version number string -->
88dfa2938af09e511e4911e6984360ded0e2cd8dLennart Poettering classname="org.opends.build.tools.CreateVersionString">
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie <getversionnumber property="VERSION_NUMBER_STRING" />
70fcff314feff469a8e61dbe5017ed74f5e0a09dLennart Poettering <!-- Generate the DynamicConstants.java file.
6f6083dc73c4bdd48678456fa6b969d6f1152373Lennart Poettering Be warned that the .stubs file references the following properties
5e6afdd3d359fc42de7ac432243e98673577e81fLennart Poettering PRODUCT_NAME, SHORT_NAME, MAJOR_VERSION, MINOR_VERSION, POINT_VERSION,
93a45c562a1989dfbb2dd08c65f8a21b02959934Lennart Poettering VERSION_QUALIFIER, FIX_IDS, timestamp, user.name, java.version,
5b754353282e3ba3cf9c4ffc50579aff4b7d72dbKay Sievers java.vendor, java.vm.version, JVM_VENDOR, DEBUG_BUILD, REVISION_NUMBER,
337eebb936be1da1215535e866965ce54c82d755Lennart Poettering WEAVE_ENABLED, VERSION_NUMBER_STRING
dfac97b21e00cd3617ba817227db7b621841b5ccLennart Poettering If you change the name of any of those properties in this build.xml
f61448083198dc0e4e0d19a916bcd478336cc85dLennart Poettering you'll need to reflect the same change in the .stubs file
2b93b027d3a68b5d7ae26d0c2cd487eb5019d2a9Lennart Poettering <condition property="BUILD_NUMBER" value="-1">
9cf2578683de834026f501c24a0f5d3d0991d0a6Dave Reisner overwrite="true" >
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <expandproperties/>
0e0320e04500d1e68630b3973714f14cfb7b3450Lennart Poettering </filterchain>
0e0320e04500d1e68630b3973714f14cfb7b3450Lennart Poettering <!-- Check modified files to see if any svn:eol-style or copyright updates
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie are needed. -->
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers <target name="checkprecommit" depends="buildtools"
ed061a8dc2acd93c2eb569d2d983d5a77f7e5b77Michal Schmidt description="Ensure updated files eol-style and copyright info">
d1ab0ca07372649dad70a0348d75e394f254e1b6Lennart Poettering classname="org.opends.build.tools.CheckPrecommit">
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers </classpath>
9cf2578683de834026f501c24a0f5d3d0991d0a6Dave Reisner <checkprecommit />
b2423f1f436f847d9fc96a63679be2b5552b6bafLennart Poettering <!-- Ensure that the source code meets basic style requirements. -->
2b93b027d3a68b5d7ae26d0c2cd487eb5019d2a9Lennart Poettering <target name="checkstyle" description="Perform basic source style checks">
3b63d2d31d0850bd7a81ab9b468218d2c4c461e8Lennart Poettering <taskdef resource="checkstyletask.properties"
3b63d2d31d0850bd7a81ab9b468218d2c4c461e8Lennart Poettering classpath="${checkstyle.dir}/checkstyle-all-4.1.jar" />
8cf3a8a982661c0bb9b04ff27f6d486b38b1b35eLennart Poettering <checkstyle config="${checkstyle.dir}/opends-checkstyle.xml"
8e1bd70d4ce6d3881c1df6a6482643a2b3a69bb1Lennart Poettering failOnViolation="true">
9cf2578683de834026f501c24a0f5d3d0991d0a6Dave Reisner <fileset dir="${src.dir}" includes="**/*.java" />
0e0320e04500d1e68630b3973714f14cfb7b3450Lennart Poettering <checkstyle config="${checkstyle.dir}/opends-checkstyle.xml"
0e0320e04500d1e68630b3973714f14cfb7b3450Lennart Poettering failOnViolation="true">
93a1d735aca5584a005d851f12cb0b8c7bb5e5caLennart Poettering <fileset dir="${ads.src.dir}" includes="**/*.java" />
35bf8dfb85c45835ec7719827aebbf7fca4c92bdKay Sievers </checkstyle>
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers <checkstyle config="${checkstyle.dir}/opends-checkstyle.xml"
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers failOnViolation="true">
d1f9edafe7b832c507931640f32069d001916b0eLennart Poettering <fileset dir="${quicksetup.src.dir}" includes="**/*.java" />
baa5ad26fd5da7bc3d7253904ac30112c94a64c2Kay Sievers <checkstyle config="${checkstyle.dir}/opends-checkstyle.xml"
e24067c3ec0e16e94e9620d4f7a06ccc4b637eb4Lennart Poettering failOnViolation="true">
5e6afdd3d359fc42de7ac432243e98673577e81fLennart Poettering <fileset dir="${statuspanel.src.dir}" includes="**/*.java" />
cd3f8b7ddb052ab5e4eab420968bae689db3899aJeff Mahoney <checkstyle config="${checkstyle.dir}/opends-doctarget-checkstyle.xml"
156730831730701cada2750e826abbf7b113861fMichal Schmidt failOnViolation="true">
156730831730701cada2750e826abbf7b113861fMichal Schmidt <fileset dir="${src.dir}/org/opends/server/api" includes="**/*.java" />
cd3f8b7ddb052ab5e4eab420968bae689db3899aJeff Mahoney <fileset dir="${src.dir}/org/opends/server/protocols/internal"
cd3f8b7ddb052ab5e4eab420968bae689db3899aJeff Mahoney includes="**/*.java" />
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov <fileset dir="${src.dir}/org/opends/server/types"
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov includes="**/*.java" />
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov </checkstyle>
156730831730701cada2750e826abbf7b113861fMichal Schmidt <checkstyle config="${checkstyle.dir}/opends-unittest-checkstyle.xml"
156730831730701cada2750e826abbf7b113861fMichal Schmidt failOnViolation="true">
1de4d79bf554946f486adf56ed765c5335816f15Andrey Borzenkov <fileset dir="${unittest.testng.src.dir}" includes="**/*.java" />
196e3fa74a88a04b0ecec7d3af648287dd088f8aMiklos Vajna </checkstyle>
196e3fa74a88a04b0ecec7d3af648287dd088f8aMiklos Vajna <checkstyle config="${checkstyle.dir}/opends-functest-checkstyle.xml"
196e3fa74a88a04b0ecec7d3af648287dd088f8aMiklos Vajna failOnViolation="true">
196e3fa74a88a04b0ecec7d3af648287dd088f8aMiklos Vajna <fileset dir="${functest.testng.src.dir}" includes="**/*.java" />
a268a6a38febcb9182cac92aaef8803f2d20d6ebFrederic Crozat </checkstyle>
a268a6a38febcb9182cac92aaef8803f2d20d6ebFrederic Crozat <!-- Compile the Directory Server source files. -->
6fdae8a6a40d6a3b5f77516abaee23b3eab002f6Dexter Morgan depends="cleaninit,compilequicksetup,weave,compilestatuspanel"
6fdae8a6a40d6a3b5f77516abaee23b3eab002f6Dexter Morgan description="Recompile the Directory Server source files.">
156730831730701cada2750e826abbf7b113861fMichal Schmidt <!-- Compile the Directory Server source files. -->
6fdae8a6a40d6a3b5f77516abaee23b3eab002f6Dexter Morgan depends="init,checkjavaversion,dynamicconstants,compileadmin"
6fdae8a6a40d6a3b5f77516abaee23b3eab002f6Dexter Morgan description="Compile the Directory Server source files.">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <javac srcdir="${src.dir}:${admin.src.dir}" destdir="${classes.dir}"
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5" target="1.5"
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers deprecation="true" fork="true" memoryInitialSize="${MEM}"
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers memoryMaximumSize="${MEM}">
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers </classpath>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <condition property="weave.enabled" value="true">
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers </condition>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <target name="weave" if="weave.enabled" depends="compile, prepweave">
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <echo message=" Weaving the source code with automatic AspectJ debug logging."/>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <echo message=" Build with -DWEAVE_ENABLED=false to turn this off."/>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <taskdef resource="org/aspectj/tools/ant/taskdefs/aspectjTaskdefs.properties">
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <pathelement location="${aj.lib.dir}/aspectjtools.jar" />
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers </classpath>
013d8a39a6178179080bcfee9122b29cf9d29259Lennart Poettering <iajc inpath="${classes.dir}" destdir="${classes.dir}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers debug="true" debuglevel="${build.debuglevel}" source="1.5" target="1.5"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers </classpath>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <!-- Compile the Quick Setup source files. -->
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <target name="compilequicksetup" depends="buildtools,weave"
9393a8774c1acd60deea40007061b9ffc783bf7eLennart Poettering description="Compile the Quick Setup source files.">
9393a8774c1acd60deea40007061b9ffc783bf7eLennart Poettering <javac srcdir="${ads.src.dir}" destdir="${quicksetup.classes.dir}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers optimize="true" debug="on" debuglevel="lines,source" source="1.5"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers memoryMaximumSize="${MEM}">
e2b696ee9bffad34daaafc99d3a5d8ee13504288Lennart Poettering <javac srcdir="${src.dir}" destdir="${quicksetup.classes.dir}"
0127336c01198ef210882207d24257cb3752718bLennart Poettering debug="on" debuglevel="${build.debuglevel}" source="1.5"
a32f224aafaf47d3489a730259a47ef45781193eLennart Poettering target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
7df46b2af58d171665fe99073188f91d567f2696Lennart Poettering memoryMaximumSize="${MEM}">
359deb60c25147e91a69c227ace686654ea7f484Lennart Poettering <include name="**/org/opends/server/util/SetupUtils.java"/>
c52f663bfa4f420044e6cd25bf84cec3c26ebf6fLennart Poettering <include name="**/org/opends/server/util/CertificateManager.java"/>
f220d83cbc63678c765dd0b80983f17b1d5e615bLennart Poettering <include name="**/org/opends/server/util/DynamicConstants.java"/>
f5ccf26ded1fd7c3d5d9c7b6615236ae051b4a34Lennart Poettering <include name="**/org/opends/server/types/OperatingSystem.java"/>
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <javac srcdir="${quicksetup.src.dir}" destdir="${quicksetup.classes.dir}"
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering debug="on" debuglevel="${build.debuglevel}" source="1.5"
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
a8eedf4953d379dc09ee2b04e69a0a54ba247a02Lennart Poettering memoryMaximumSize="${MEM}">
6b7b92055db40070676bf3c0539a27569c1203b6Lennart Poettering includes="**/*.properties, **/*.gif, **/*.png" />
e2b696ee9bffad34daaafc99d3a5d8ee13504288Lennart Poettering <!-- Compile the Status Panel source files. -->
e2b696ee9bffad34daaafc99d3a5d8ee13504288Lennart Poettering <target name="compilestatuspanel" depends="compilequicksetup"
0127336c01198ef210882207d24257cb3752718bLennart Poettering description="Compile the Status Panel source files.">
0127336c01198ef210882207d24257cb3752718bLennart Poettering <mkdir dir="${statuspanel.classes.dir}" />
0127336c01198ef210882207d24257cb3752718bLennart Poettering <javac srcdir="${statuspanel.src.dir}" destdir="${statuspanel.classes.dir}"
0127336c01198ef210882207d24257cb3752718bLennart Poettering debug="on" debuglevel="${build.debuglevel}" source="1.5"
a32f224aafaf47d3489a730259a47ef45781193eLennart Poettering target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
7df46b2af58d171665fe99073188f91d567f2696Lennart Poettering memoryMaximumSize="${MEM}">
ff5d32c875fe5507db2004d3c22fe77cbc7eab0dLennart Poettering <pathelement path="${quicksetup.classes.dir}"/>
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <copy todir="${statuspanel.classes.dir}">
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering includes="**/*.properties, **/*.gif, **/*.png" />
a8eedf4953d379dc09ee2b04e69a0a54ba247a02Lennart Poettering ! Rebuild the Directory Server without destroying any existing configuration
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers ! or data. It will only overwrite the libraries, classes, and scripts, and
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers ! it will not re-package. It will also not do a complete initialization, so
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers ! DynamicConstants.java won't be regenerated.
9393a8774c1acd60deea40007061b9ffc783bf7eLennart Poettering description="Rebuild the server without destroying config or data.">
ee1c0ad436efef9d2688a48917bf77d65a0ce675Lennart Poettering <!-- Set the amount of memory to use for the build -->
ee1c0ad436efef9d2688a48917bf77d65a0ce675Lennart Poettering <!-- Construct the version number string -->
e2b696ee9bffad34daaafc99d3a5d8ee13504288Lennart Poettering classname="org.opends.build.tools.CreateVersionString">
7df46b2af58d171665fe99073188f91d567f2696Lennart Poettering <getversionnumber property="VERSION_NUMBER_STRING" />
ff5d32c875fe5507db2004d3c22fe77cbc7eab0dLennart Poettering <!-- Set properties needed to find the packaged files -->
ff5d32c875fe5507db2004d3c22fe77cbc7eab0dLennart Poettering location="${package.dir}/OpenDS-${VERSION_NUMBER_STRING}" />
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <!-- Clean up a minimal set of files/directories for the rebuild. -->
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <delete file="${package.dir}/lib/OpenDS.jar" />
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <delete dir="${quicksetup.classes.dir}" />
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <delete file="${package.dir}/lib/quicksetup.jar" />
12355095821fc17529af5b6eaefa31c3c520be39Lennart Poettering <delete file="${package.dir}/lib/statuspanel.jar" />
a8eedf4953d379dc09ee2b04e69a0a54ba247a02Lennart Poettering <!-- Regenerate configuration files if necessary -->
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <!-- Recreate the classes directory and recompile into it. -->
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <javac srcdir="${src.dir}:${admin.src.dir}" destdir="${classes.dir}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5" target="1.5"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers deprecation="true" fork="true" memoryInitialSize="${MEM}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers memoryMaximumSize="${MEM}">
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers </classpath>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <!-- Generate the OpenDS.jar file -->
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers basedir="${classes.dir}" compress="true" index="true" />
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <!-- Recreate the quicksetup classes directory and recompile into it. -->
139be57d9441b5c890e1e4ee69e15aad03276fdeLennart Poettering <javac srcdir="${ads.src.dir}" destdir="${quicksetup.classes.dir}"
49e942b2bc9fdedba79cd266a076ce9c9d91fc13Kay Sievers optimize="true" debug="on" debuglevel="lines,source" source="1.5"
c0a0872d5c5a0e948c3ace0fb1578a64840ebc8eLennart Poettering target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
c0a0872d5c5a0e948c3ace0fb1578a64840ebc8eLennart Poettering memoryMaximumSize="${MEM}">
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers </classpath>
9eb977db5b89b44f254ab40c1876a76b7d7ea2d0Kay Sievers <javac srcdir="${src.dir}" destdir="${quicksetup.classes.dir}"
9eb977db5b89b44f254ab40c1876a76b7d7ea2d0Kay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5"
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers memoryMaximumSize="${MEM}">
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <include name="**/org/opends/server/util/SetupUtils.java"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <include name="**/org/opends/server/util/CertificateManager.java"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <include name="**/org/opends/server/util/DynamicConstants.java"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <include name="**/org/opends/server/types/OperatingSystem.java"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <javac srcdir="${quicksetup.src.dir}" destdir="${quicksetup.classes.dir}"
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5" target="1.5"
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers deprecation="true" fork="true" memoryInitialSize="${MEM}"
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers memoryMaximumSize="${MEM}">
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers </classpath>
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers includes="**/*.properties, **/*.gif, **/*.png"/>
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers <!-- Generate the quicksetup.jar file -->
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers basedir="${quicksetup.classes.dir}" compress="true" index="true" />
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers <!-- Recreate the statuspanel classes directory and recompile into it. -->
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers <javac srcdir="${statuspanel.src.dir}" destdir="${statuspanel.classes.dir}"
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5" target="1.5"
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers deprecation="true" fork="true" memoryInitialSize="${MEM}"
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers memoryMaximumSize="${MEM}">
bd5b0d57ef3fceef3ed61d0e06a8e1f3d8417048Lennart Poettering <copy todir="${statuspanel.classes.dir}">
bd5b0d57ef3fceef3ed61d0e06a8e1f3d8417048Lennart Poettering includes="**/*.properties, **/*.gif, **/*.png"/>
3bdf9c1d0a241eff2d17591854172725682b27cdKay Sievers <!-- Generate the statuspanel.jar file -->
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering basedir="${statuspanel.classes.dir}" compress="true" index="true" />
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers <!-- Regenerate example plugin. -->
49e942b2bc9fdedba79cd266a076ce9c9d91fc13Kay Sievers <!-- Populate the Directory Server package, but don't zip it up. -->
477572f5c7ffc2febc75277ca84d15bd151d42caKay Sievers <target name="prepackage" depends="cleancompile"
49e942b2bc9fdedba79cd266a076ce9c9d91fc13Kay Sievers description="Prepare the Directory Server package structure.">
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers location="${package.dir}/OpenDS-${VERSION_NUMBER_STRING}" />
88f642c00b1708c5e0203c1753a9ef91d1de5442Kay Sievers basedir="${classes.dir}" compress="true" index="true" />
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers basedir="${quicksetup.classes.dir}" compress="true" index="true" />
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering <jar jarfile="${pdir}/lib/statuspanel.jar"
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering basedir="${statuspanel.classes.dir}" compress="true" index="true" />
41e5171419f5f9c08a338ea8b2ab8ea89c23c4abLennart Poettering <fixcrlf srcDir="${scripts.dir}" destDir="${pdir}/bin" excludes="*.bat,_client-script.sh,_server-script.sh" eol="lf" />
41e5171419f5f9c08a338ea8b2ab8ea89c23c4abLennart Poettering <fixcrlf srcDir="${scripts.dir}" destDir="${pdir}/lib" includes="_client-script.sh,_server-script.sh" eol="lf" />
41e5171419f5f9c08a338ea8b2ab8ea89c23c4abLennart Poettering <fixcrlf srcDir="${scripts.dir}" destDir="${pdir}/bin" includes="README_WINDOWS.txt" eol="crlf" />
41e5171419f5f9c08a338ea8b2ab8ea89c23c4abLennart Poettering <fixcrlf srcDir="${scripts.dir}" destDir="${pdir}/bat" excludes="_client-script.bat,_server-script.bat,setcp.bat" includes="*.bat" eol="crlf" />
41e5171419f5f9c08a338ea8b2ab8ea89c23c4abLennart Poettering <fixcrlf srcDir="${scripts.dir}" destDir="${pdir}/lib" includes="_client-script.bat,_server-script.bat,setcp.bat" eol="crlf" />
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers tofile="${pdir}/config/upgrade/config.ldif.${REVISION_NUMBER}" />
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers classname="org.opends.build.tools.ConcatSchema">
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers </classpath>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <concatschema schemaDirectory="${resource.dir}/schema"
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers toFile="${pdir}/config/upgrade/schema.ldif.${REVISION_NUMBER}" />
78b2e3a632748fbeae8a9eb70ab1940e4a70619aKay Sievers <fixcrlf srcDir="${resource.dir}" destDir="${pdir}" includes="setup,uninstall,upgrade"
78b2e3a632748fbeae8a9eb70ab1940e4a70619aKay Sievers <fixcrlf srcDir="${resource.dir}" destDir="${pdir}" includes="setup.bat,uninstall.bat,upgrade.bat"
79c077224be5a868d0bba66972ef9546dae85977Kay Sievers eol="crlf" />
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <chmod file="${pdir}/lib/_client-script.sh" perm="755" />
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <chmod file="${pdir}/lib/_server-script.sh" perm="755" />
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <!-- Package the Directory Server for distribution. -->
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers description="Package the Directory Server for distribution.">
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <zip destfile="${package.dir}/OpenDS-${VERSION_NUMBER_STRING}.zip">
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <zipfileset dir="${package.dir}" includes="OpenDS-${VERSION_NUMBER_STRING}/**/*"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers excludes="OpenDS-${VERSION_NUMBER_STRING}/bin/*,OpenDS-${VERSION_NUMBER_STRING}/lib/_client-script.sh,OpenDS-${VERSION_NUMBER_STRING}/lib/_server-script.sh,OpenDS-${VERSION_NUMBER_STRING}/setup,OpenDS-${VERSION_NUMBER_STRING}/uninstall,OpenDS-${VERSION_NUMBER_STRING}/upgrade"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers includes="OpenDS-${VERSION_NUMBER_STRING}/lib/_client-script.sh,OpenDS-${VERSION_NUMBER_STRING}/lib/_server-script.sh"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <zipfileset dir="${package.dir}" includes="OpenDS-${VERSION_NUMBER_STRING}/bin/*"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers excludes="OpenDS-${VERSION_NUMBER_STRING}/bin/README_WINDOWS.txt"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <zipfileset dir="${package.dir}" includes="OpenDS-${VERSION_NUMBER_STRING}/bin/README_WINDOWS.txt"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <zipfileset dir="${package.dir}" includes="OpenDS-${VERSION_NUMBER_STRING}/setup,OpenDS-${VERSION_NUMBER_STRING}/uninstall,OpenDS-${VERSION_NUMBER_STRING}/upgrade"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <!-- Prepare the Directory Server DSML library. -->
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers description="Prepare the Directory Server DSML library.">
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <taskdef name="xjc" classname="com.sun.tools.xjc.XJCTask">
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers </classpath>
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <mkdir dir="${dsml.gen.dir}/org/opends/dsml/protocol" />
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <xjc target="${dsml.gen.dir}" schema="${dsml.dir}/schema/DSMLv2.xsd"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers removeOldOutput="yes" package="org.opends.dsml.protocol">
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <produces dir="${dsml.gen.dir}/org/opends/dsml/protocol"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers includes="* impl/*" />
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <javac srcdir="${dsml.gen.dir}" destdir="${dsml.classes.dir}"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers memoryMaximumSize="${MEM}">
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers </classpath>
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <javac srcdir="${dsml.src.dir}" destdir="${dsml.classes.dir}"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers memoryMaximumSize="${MEM}">
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering <war destfile="${classes.dir}/OpenDS-${VERSION_NUMBER_STRING}-DSML.war"
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering <fileset file="${dsml.dir}/webapp/server.properties" />
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers <webinf dir="${dsml.dir}/webapp" includes="**/*"
b30e2f4c18ad81b04e4314fd191a5d458553773cKay Sievers excludes="web.xml, **/*.jar, **/*.properties" />
139be57d9441b5c890e1e4ee69e15aad03276fdeLennart Poettering <!-- Generate JavaDoc documentation from the source files -->
139be57d9441b5c890e1e4ee69e15aad03276fdeLennart Poettering <target name="javadoc" depends="dsml,compileadmin"
4927fcae48de061393b3ce9c12d49f80d73fbf1dLennart Poettering description="Generate JavaDoc documentation.">
4536f71691f6bbf40e1c82856850e0b7057b6e9dFrederic Crozat <javadoc destdir="${javadoc.dir}" source="1.5" additionalparam="-quiet"
139be57d9441b5c890e1e4ee69e15aad03276fdeLennart Poettering linksource="yes" windowtitle="${PRODUCT_NAME} API Documentation"
139be57d9441b5c890e1e4ee69e15aad03276fdeLennart Poettering maxmemory="${MEM}">
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <!-- Internal target to prepare to generate a code coverage report. -->
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <property name="coverage.enabled" value="true" />
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <pathelement location="${classes.dir}" />
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <!-- Prepare to execute the Directory Server TestNG unit tests. -->
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <target name="testinit" depends="buildtools, weave"
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers description="Prepare to execute the Directory Server TestNG unit tests.">
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <!-- If we are to perform coverage tests, then set that up. -->
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <pathelement location="${emma.dir}/emma_ant.jar" />
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <taskdef resource="emma_ant.properties" classpathref="emma.lib" />
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <instr instrpathref="run.classpath" destdir="${coverage.instr.dir}"
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers metadatafile="${coverage.data.dir}/metadata.emma" merge="true" />
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <!-- Compile the test cases -->
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers <javac srcdir="${unittest.testng.src.dir}" destdir="${unittest.classes.dir}"
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5"
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers memoryMaximumSize="${MEM}">
90ccc3fca7e53a60a9e67b9d5812e1d4a27fc07dKay Sievers </classpath>
590f18a27c05524f5332819b9580afc327b95d84Lennart Poettering <!-- Prep the TestNG XML file -->
590f18a27c05524f5332819b9580afc327b95d84Lennart Poettering <condition property="test.groups" value="exclude=slow">
9b80f05fb727edc70a305d912ab6cf1c3bdbf67eKay Sievers </condition>
6cbf079f10ba998e4d8debb7f5b7dab4efaae3d0Kay Sievers <condition property="test.packages" value="org.opends.server.*">
6cbf079f10ba998e4d8debb7f5b7dab4efaae3d0Kay Sievers </condition>
b0193f1c1f1540bfccbdca02df82669b9308e4e2Lennart Poettering <condition property="test.classes" value="">
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <condition property="test.methods" value="">
b6358b8d762253a1f9ebd82135ff1053dc796b88Kay Sievers </condition>
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <typedef name="preptestng" classname="org.opends.build.tools.PrepTestNG"
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering classpath="${build.dir}/build-tools/build-tools.jar" />
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers grouplist="${test.groups}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers packagelist="${test.packages}"
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers classList="${test.classes}"
e0209d83e7b30153f43b1a633c955f66eb2c2e4aMichal Schmidt methodList="${test.methods}" />
47be870bd83fb3719dffc3ee9348a409ab762a14Lennart Poettering <antcall target="testinit.checkFailedTestsOnly"/>
235450b0d1b7269476b8a19bb20b016d2d3ffc46Kay Sievers <!-- If we were asked to run only the tests that failed,
15ae422b7471cf6f41ccf450243d8afd8ea0a054Lennart Poettering then we overwrite the testng.xml that we just generated
af5bc85dc1297079edc9890861aaa38de0ec30dfLennart Poettering with testng-failed.xml, which TestNG generated. -->
379079ba6b06e82de9a8f0025456308a34b4b115Lennart Poettering <target name="testinit.checkFailedTestsOnly" if="test.failures">
af5bc85dc1297079edc9890861aaa38de0ec30dfLennart Poettering <!-- Ensure that some of the tests failed last time. -->
139be57d9441b5c890e1e4ee69e15aad03276fdeLennart Poettering <available property="testng-failed.xml.exists"
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering file="${unittest.report.dir}/testng-failed.xml"/>
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering <fail message="No unit tests failed in the previous run."
379079ba6b06e82de9a8f0025456308a34b4b115Lennart Poettering <!-- We replace the 'Failed suite [OpenDS]' with 'OpenDS' so we
e59077036bcf5a041e336f04cb0d2f7d18d489a1Lennart Poettering don't end up with 'Failed suite [Failed suite [OpenDS]]]' etc. -->
e59077036bcf5a041e336f04cb0d2f7d18d489a1Lennart Poettering <replace file="${unittest.report.dir}/testng-failed.xml"
4d8961391719a1dd7a20f15e3f7d4df47988fbcfLennart Poettering token="Failed suite [OpenDS]"
e59077036bcf5a041e336f04cb0d2f7d18d489a1Lennart Poettering value="OpenDS"/>
b0193f1c1f1540bfccbdca02df82669b9308e4e2Lennart Poettering <replace file="${unittest.report.dir}/testng-failed.xml"
b0193f1c1f1540bfccbdca02df82669b9308e4e2Lennart Poettering token="default(failed)"
b0193f1c1f1540bfccbdca02df82669b9308e4e2Lennart Poettering value="default"/>
b0193f1c1f1540bfccbdca02df82669b9308e4e2Lennart Poettering <copy file="${unittest.report.dir}/testng-failed.xml"
b0193f1c1f1540bfccbdca02df82669b9308e4e2Lennart Poettering tofile="${unittest.resource.dir}/testng.xml"
8c47c7325fa1ab72febf807f8831ff24c75fbf45Lennart Poettering overwrite="true"/>
af5bc85dc1297079edc9890861aaa38de0ec30dfLennart Poettering <echo message="Will run the failed unit tests only"/>
8c6db8336536916d0476ff8233e0abf40a2f6aabLennart Poettering <!-- Generate coverage diff report -->
8c6db8336536916d0476ff8233e0abf40a2f6aabLennart Poettering <condition property="test.diff.srcpath" value="">
379079ba6b06e82de9a8f0025456308a34b4b115Lennart Poettering <condition property="test.diff.enabled" value="true">
379079ba6b06e82de9a8f0025456308a34b4b115Lennart Poettering <condition property="test.diff.verbose" value="false">
379079ba6b06e82de9a8f0025456308a34b4b115Lennart Poettering <condition property="test.diff.enabled" value="false">
830964834f330836b9d33752e83de09d4f38da87Lennart Poettering <taskdef name="coveragediff" classname="org.opends.build.tools.CoverageDiff">
dce818b390a857a11f7dd634684500675cf79833Kay Sievers <coveragediff emmadatapath="${coverage.data.dir}"
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers verbose="${test.diff.verbose}" />
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <!-- Execute the Directory Server TestNG unit tests in text mode. -->
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <!-- Execute Directory Server TestNG unit tests specified from CLI -->
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <echo message="This target is deprecated. Please use the test target as it now supports the test.* properties." />
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <!-- Execute all of the Directory Server TestNG unit tests in text mode. -->
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers depends="enableTestNGAssertions,prepdefaultalltest,testinit,runtests"
dce818b390a857a11f7dd634684500675cf79833Kay Sievers description="Run all of the TestNG tests (including 'slow' ones) with assertions enabled. See 'testwithcoverage' for properties you can set.">
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <!-- Execute the Directory Server TestNG unit tests in text mode. -->
04ebb5956719e3e301e1c08443c496ad97399544Lennart Poettering depends="testinit,runtests"
04ebb5956719e3e301e1c08443c496ad97399544Lennart Poettering description="Execute the Directory Server TestNG unit tests in text mode. Set '-Dorg.opends.test.suppressOutput=false' to see the output from the unit tests. Set '-Dtest.failures=true' to run only the tests that failed previously.">
146de8175e11c877908f20f8ed1b5a3805455c0aLennart Poettering <!-- Execute the Directory Server TestNG unit tests in text mode with a coverage report. -->
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering depends="coverage,test,coveragediff"
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering description="Execute the Directory Server TestNG unit tests in text mode with a coverage report. Use -Dtest.packages, -Dtest.classes, or -Dtest.methods to control which unit tests are run. Use -Dtest.diff.srcpath to control which src files show up in the coverage diff. See the 'test' package for other properties you can set.">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Execute the Directory Server TestNG unit tests in text mode with a coverage report and slow tests. -->
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers depends="coverage,testall,coveragediff"
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers description="The same as 'testwithcoverage' except 'testall' is run instead of 'test'.">
83684a3553cd875d6873b3dc867e6cd1a7cc4173Tom Gundersen <!-- Execute the Directory Server TestNG unit tests specified from CLI in text mode with a coverage report. -->
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message="This target is deprecated. Please use the testwithcoverage target as it now supports the test.* properties." />
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <target name="testhelp" unless="disable.test.help">
dce818b390a857a11f7dd634684500675cf79833Kay Sievers <echo message="About to run the unit tests. Ant options to control the tests:"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" -Dorg.opends.test.suppressOutput=false"/>
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers <echo message=" writes the unit test output to the screen"/>
d4a66a7f9638d4c642356d1fb9e38ac29766a451Kay Sievers <echo message=" -Dorg.opends.test.pauseOnFailure=true"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <echo message=" pauses the test suite whenever a failure occurs allowing you to inspect"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" the server more closely in the failure state"/>
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering <echo message=" runs only the tests that failed last time"/>
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers <echo message=" builds the server without the debug logging facility." />
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers <echo message=" No debug logging messages will be included on test failures." />
d4a66a7f9638d4c642356d1fb9e38ac29766a451Kay Sievers <echo message=" -Dorg.opends.test.debug.target=org.opends.server.core:level=verbose,category=data"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <echo message=" for example only include debug messages in the core"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" package that are related to data access and at the" />
dce818b390a857a11f7dd634684500675cf79833Kay Sievers <echo message=" verbose level or higher. The syntax of this target" />
d4a66a7f9638d4c642356d1fb9e38ac29766a451Kay Sievers <echo message=" definition is the same as the org.opends.server.debug.target.x" />
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" property when starting OpenDS. " />
d4a66a7f9638d4c642356d1fb9e38ac29766a451Kay Sievers <echo message=" org.opends.server:level=warning,category=caught|data|database-access|message|protocol" />
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <echo message=" -Dtest.packages=org.opends.server.api"/>
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <echo message=" for example runs only the tests in the api package"/>
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <echo message=" For multiple packages, separate them with a ',' and "/>
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <echo message=" quote the entire value. Debug logging is disabled."/>
6edd7d0a09171ea5ae8e01b7b1cbcb0bdfbfeb16Lennart Poettering <echo message=" -Dtest.classes=org.opends.server.types.TestDN"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <echo message=" for example only runs the TestDN class"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" For multiple classes, separate them with a ',' and "/>
dce818b390a857a11f7dd634684500675cf79833Kay Sievers <echo message=" quote the entire value. Debug logging is disabled."/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" -Dtest.methods=org.opends.server.types.TestDN.testGetRDN"/>
f4b4781191e8edfb5690e4447166e3ba7bcb48f5Lennart Poettering <echo message=" for example only runs the testGetRDN method"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <echo message=" For multiple methods, separate them with a ',' and "/>
87d2c1ff6a7375f03476767e6f59454bcc5cd04bLennart Poettering <echo message=" quote the entire value. Debug logging is disabled."/>
49e942b2bc9fdedba79cd266a076ce9c9d91fc13Kay Sievers <echo message=" -Dtest.diff.srcpath=src/server/org/opends/server/core"/>
bd5b0d57ef3fceef3ed61d0e06a8e1f3d8417048Lennart Poettering <echo message=" for example includes only the classes in"/>
b7739c77dff36332db79118b42f34babeef9e05eKay Sievers <echo message=" src/server/org/opends/server/core in the coveragediff report."/>
807e17f05e217b474af39503efb9503d81b12596Lennart Poettering <echo message=" To list multiple directories or files, separate them with"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <echo message=" a space as you would an argument list to 'svn diff' and quote"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <!-- Internal target to execute the Directory Server TestNG unit tests in text mode after everything has been initialized. -->
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <!-- This sets TESTASSERT to false if and only if it's not already set. -->
27b5482cc08b7fac1b6b15d980d42ae04f3ae1caLennart Poettering <condition property="TESTASSERT" value="false">
27b5482cc08b7fac1b6b15d980d42ae04f3ae1caLennart Poettering <!-- This sets org.opends.test.suppressOutput if and only if it's not
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers already set. -->
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <condition property="org.opends.test.suppressOutput" value="true">
f61448083198dc0e4e0d19a916bcd478336cc85dLennart Poettering <isset property="org.opends.test.suppressOutput" />
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers </condition>
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers <!-- This sets org.opends.test.pauseOnFailure if and only if it's not
6b1dc2bd3cdb3bd932b0692be636ddd2879edb92Lennart Poettering already set. -->
6b1dc2bd3cdb3bd932b0692be636ddd2879edb92Lennart Poettering <condition property="org.opends.test.pauseOnFailure" value="false">
6b1dc2bd3cdb3bd932b0692be636ddd2879edb92Lennart Poettering <isset property="org.opends.test.pauseOnFailure" />
6b1dc2bd3cdb3bd932b0692be636ddd2879edb92Lennart Poettering <!-- This sets org.opends.test.debug.target if and only if its's not
6b1dc2bd3cdb3bd932b0692be636ddd2879edb92Lennart Poettering alreadly set. -->
d360705f0f1262d49cccb6507abeafb7cfb5bbe0Lennart Poettering <condition property="org.opends.test.debug.target"
d360705f0f1262d49cccb6507abeafb7cfb5bbe0Lennart Poettering value="org.opends.server:level=warning,category=caught|data|database_access|message|protocol">
d360705f0f1262d49cccb6507abeafb7cfb5bbe0Lennart Poettering <isset property="org.opends.test.debug.target" />
d360705f0f1262d49cccb6507abeafb7cfb5bbe0Lennart Poettering <!-- Cleanout the old reports. Otherwise, the old testng-failed.xml
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers will hang around even if all of the tests pass. -->
dce818b390a857a11f7dd634684500675cf79833Kay Sievers <fileset dir="${unittest.report.dir}" includes="*"/>
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers <!-- Our testng listener will remove this file if all of the
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers tests passed. This allows us to generate the coverage
7e8f489ad5ac0c48d9d0b2d1a424e8913c77c11dKay Sievers report even if the tests failed and still fail the build. -->
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <touch file="${unittest.report.dir}/.tests-failed-marker"/>
2b93b027d3a68b5d7ae26d0c2cd487eb5019d2a9Lennart Poettering <testng outputdir="${unittest.report.dir}"
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering haltonfailure="false"
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering enableAssert="${TESTASSERT}"
609518c1d2abb511bd1fce447a1aa369e92a0bdbKay Sievers listeners="org.opends.server.TestListener org.testng.reporters.FailedReporter"
2b93b027d3a68b5d7ae26d0c2cd487eb5019d2a9Lennart Poettering useDefaultListeners="false"
49e942b2bc9fdedba79cd266a076ce9c9d91fc13Kay Sievers suiteRunnerClass="org.opends.server.SuiteRunner">
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers <pathelement location="${coverage.instr.dir}" />
dce818b390a857a11f7dd634684500675cf79833Kay Sievers <pathelement location="${unittest.classes.dir}" />
dce818b390a857a11f7dd634684500675cf79833Kay Sievers </classpath>
f401e48c2db22ff9d1a05885b5599bebf19c2707Lennart Poettering <jvmarg value="-Demma.coverage.out.file=${coverage.data.dir}/unit.emma" />
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <jvmarg value="-Demma.coverage.out.merge=false" />
f401e48c2db22ff9d1a05885b5599bebf19c2707Lennart Poettering <jvmarg value="-Dorg.opends.server.BuildRoot=${basedir}" />
f401e48c2db22ff9d1a05885b5599bebf19c2707Lennart Poettering <jvmarg value="-Dorg.opends.server.RunningUnitTests=true" />
f401e48c2db22ff9d1a05885b5599bebf19c2707Lennart Poettering <jvmarg value="-Dorg.opends.test.suppressOutput=${org.opends.test.suppressOutput}" />
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <jvmarg value="-Dorg.opends.test.pauseOnFailure=${org.opends.test.pauseOnFailure}" />
477572f5c7ffc2febc75277ca84d15bd151d42caKay Sievers <jvmarg value="-Dorg.opends.test.debug.target=${org.opends.test.debug.target}" />
f401e48c2db22ff9d1a05885b5599bebf19c2707Lennart Poettering <xmlfileset dir="${unittest.resource.dir}" includes="testng.xml" />
bd5b0d57ef3fceef3ed61d0e06a8e1f3d8417048Lennart Poettering <!-- Our testng listener will create this file if any of the
41e5171419f5f9c08a338ea8b2ab8ea89c23c4abLennart Poettering tests failed. This allows us to generate the coverage
f401e48c2db22ff9d1a05885b5599bebf19c2707Lennart Poettering report even if the tests failed. -->
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers file="${unittest.report.dir}/.tests-failed-marker"/>
e5e83e8362e946890ac991fc86a2c5869f9befdfLennart Poettering <!-- Delete all of the report suite sub-directories since we only
1822350db15b089f094a6dbd2469842ab42c1d87Kay Sievers have a single suite. -->
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers <txt outfile="${coverage.report.dir}/coverage.txt" />
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers <html outfile="${coverage.report.dir}/index.html" />
681cfc6c40b176f73204c9088bfc5a7e8bad4317Kay Sievers <xml outfile="${coverage.report.dir}/coverage.xml" />
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <!-- We delay failing until after the coverage report is generated. -->
49e942b2bc9fdedba79cd266a076ce9c9d91fc13Kay Sievers <fail message="The unit tests failed." if="testng.tests.failed"/>
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers </condition>
08e1fb68d78b4adf26cce8387fc428b9e370bcf4Lennart Poettering ! Previously a dependency of the nightly, all, testall and test targets.
4668191d0298339c70fba485f46233f79fcedc30Kay Sievers ! Weaving is now disabled by default due to the excessive need for memory
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers ! during weaving.
f33d3ec1d7521c91da8b30ad5cb345d6416bb07dKay Sievers <condition property="WEAVE_ENABLED" value="true">
d7832d2c6e0ef5f2839a2296c1cc2fc85c7d9632Kay Sievers </condition>
cc527a4734d636f1ab5a66576cb7e232af3cc261Kay Sievers depends="test"
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers description="Takes testng results and convert them into JUnit compatible xml">
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers <report format="noframes" todir="${unittest.report.dir}"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers </junitreport>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers description="Builds the integration tests">
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <ant dir="${functest.testng.dir}" inheritall="false"/>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers description="Builds the build tools">
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <!-- Set the amount of memory to use for the build -->
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers </condition>
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers <javac srcdir="${buildtools.src.dir}" destdir="${buildtools.classes.dir}"
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers debug="on" debuglevel="${build.debuglevel}" source="1.5"
2a018e83ded29c9719b2478a65ee6245c829c0f5Kay Sievers target="1.5" deprecation="true" fork="true" memoryInitialSize="${MEM}"
48d437bbf10aa80d37b280ed946a51dee5bc69b8Kay Sievers memoryMaximumSize="${MEM}">
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers </classpath>
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers <jar jarfile="${build.dir}/build-tools/build-tools.jar"
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers basedir="${buildtools.classes.dir}" compress="true" index="true" />
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers <!-- Code generation for core administration components. -->
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers <target name="compileadmin" depends="validateadmin" description="Code generation for configuration Object.">
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers <!-- The XSLT task creates a lot of noise.
9ace5d028ea1c32af70f123cf7fa4200b12f8c93Kay Sievers I can't find any other way to shut it up. -->
d41ba529b4d7a57456c030e5d20546e6f0abfef3Kay Sievers </condition>
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers </condition>
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers <!-- Generate introspection API for core administration components. -->
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.src.dir}" includes="**/*Configuration.xml" style="${admin.rules.dir}/metaMO.xsl">
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)Configuration\.xml$$" to="\1/meta/\2CfgDefn.java" />
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers <param name="base-dir" expression="${admin.defn.dir}" />
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.src.dir}" includes="**/Package.xml" style="${admin.rules.dir}/package-info.xsl">
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)\.xml$$" to="\1/meta/package-info.java" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Generate client API for core administration components. -->
20bbd54f603994a3cc211d2795de16550882ed8dKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.src.dir}" includes="**/*Configuration.xml" style="${admin.rules.dir}/clientMO.xsl">
20bbd54f603994a3cc211d2795de16550882ed8dKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)Configuration\.xml$$" to="\1/client/\2CfgClient.java" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <param name="base-dir" expression="${admin.defn.dir}" />
33502ffe2eb7b56cdd018a4fb6830d7828519fadKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.src.dir}" includes="**/Package.xml" style="${admin.rules.dir}/package-info.xsl">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)\.xml$$" to="\1/client/package-info.java" />
20bbd54f603994a3cc211d2795de16550882ed8dKay Sievers <!-- Generate server API for core administration components. -->
20bbd54f603994a3cc211d2795de16550882ed8dKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.src.dir}" includes="**/*Configuration.xml" style="${admin.rules.dir}/serverMO.xsl">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)Configuration\.xml$$" to="\1/server/\2Cfg.java" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <param name="base-dir" expression="${admin.defn.dir}" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.src.dir}" includes="**/Package.xml" style="${admin.rules.dir}/package-info.xsl">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)\.xml$$" to="\1/server/package-info.java" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Generate LDAP profile for core administration components. -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${classes.dir}/admin/profiles/ldap" includes="**/*Configuration.xml" style="${admin.rules.dir}/ldapMOProfile.xsl">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)Configuration\.xml$$" to="\1/meta/\2CfgDefn.properties" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <param name="base-dir" expression="${admin.defn.dir}" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Generate I18N messages for core administration components. -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${classes.dir}/admin/messages" includes="**/*Configuration.xml" style="${admin.rules.dir}/messagesMO.xsl">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <regexpmapper handledirsep="true" from="^(.*)/([^/]+)Configuration\.xml$$" to="\1/meta/\2CfgDefn.properties" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <param name="base-dir" expression="${admin.defn.dir}" />
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <!-- Generate manifest file for core administration components. -->
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <tempfile property="admin.temp.dir" destDir="${build.dir}" prefix="tmp" />
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <xslt basedir="${admin.defn.dir}" destdir="${admin.temp.dir}" extension=".manifest" includes="**/*Configuration.xml" style="${admin.rules.dir}/manifestMO.xsl"/>
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers <concat destfile="${classes.dir}/admin/core.manifest">
bb061708d5aa83579f213bdfb67253f7027217c3Kay Sievers <fileset dir="${admin.temp.dir}" includes="**/*.manifest" />
e9a5ef7cddcfcdb29b5aef3896931132b6fd5165Kay Sievers <!-- Remove all dynamically-generated build files. -->
04a9d3a00a9290cbf254d0b0ba2ce4521be632aeKay Sievers <target name="cleanadmin" description="Clean up any generated source files for admin">
cc0933371d5a19c1a102ce911cb01aae8909b949Kay Sievers <fileset dir="${admin.src.dir}" includes="**/*" />
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers <!-- Validate core administration component XML definition files. -->
cc0933371d5a19c1a102ce911cb01aae8909b949Kay Sievers <target name="validateadmin" description="Validate core administration component XML definition files.">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <schemavalidate>
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <fileset dir="${admin.defn.dir}" includes="**/*.xml" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <schema namespace="http://www.opends.org/admin" file="${admin.rules.dir}/admin.xsd"/>
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <schema namespace="http://www.opends.org/admin-ldap" file="${admin.rules.dir}/admin-ldap.xsd"/>
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers </schemavalidate>
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Generate a src.zip file containing all the server source. -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers description="Generate a src.zip file with all the server source.">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <zipfileset dir="${src.dir}" excludes="**/.svn" filemode="644"
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers dirmode="755" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <zipfileset dir="${admin.src.dir}" excludes="**/.svn" filemode="644"
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers dirmode="755" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <zipfileset dir="${ads.src.dir}" excludes="**/.svn" filemode="644"
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers dirmode="755" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <zipfileset dir="${quicksetup.src.dir}" excludes="**/.svn" filemode="644"
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers dirmode="755" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <zipfileset dir="${statuspanel.src.dir}" excludes="**/.svn" filemode="644"
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers dirmode="755" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Generate example plugin package. -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Create folder hierarchy in temporary directory. -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <tempfile property="plugin.temp.dir" destDir="${build.dir}" prefix="tmp"/>
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/src" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/src-generated" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/lib" />
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie <mkdir dir="${plugin.temp.dir}/example-plugin/ext" />
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/resource" />
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/resource/admin" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/resource/config" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <mkdir dir="${plugin.temp.dir}/example-plugin/resource/schema" />
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie <copy todir="${plugin.temp.dir}/example-plugin/src">
f13b388f97bc3ba8db844bd3413d510e2466a0b6Kay Sievers <fileset dir="${admin.defn.dir}" includes="**/*.xml" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <copy todir="${plugin.temp.dir}/example-plugin/resource/admin">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <fileset dir="${admin.rules.dir}" excludes="example-plugin/**" />
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie <copy todir="${plugin.temp.dir}/example-plugin" file="${admin.rules.dir}/example-plugin/build.xml" />
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie <copy todir="${plugin.temp.dir}/example-plugin" file="${admin.rules.dir}/example-plugin/README" />
49e7f0277444ca10623fe790ff754f7c006f8c64Lennart Poettering <copy todir="${plugin.temp.dir}/example-plugin/resource/schema" file="${admin.rules.dir}/example-plugin/99-example-plugin.ldif" />
51dfddc2cceb345ffc994014e4a4b3f2d2d3a3aaColin Guthrie <copy todir="${plugin.temp.dir}/example-plugin/resource/config" file="${admin.rules.dir}/example-plugin/example-plugin.ldif" />
49e7f0277444ca10623fe790ff754f7c006f8c64Lennart Poettering <copy todir="${plugin.temp.dir}/example-plugin/src/com/example/opends">
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <fileset dir="${admin.rules.dir}/example-plugin" includes="*.java,*.xml" excludes="build.xml" />
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <!-- Package up the plugin in the OpenDS package folder. -->
3e2147858f21943d5f4a781c60f33ac22c6096edKay Sievers <zipfileset dir="${plugin.temp.dir}" filemode="644" dirmode="755" />