pom.xml revision 2e056544b859bdd14504fb8357e4298e86b23e2a
<?xml version="1.0" encoding="UTF-8"?>
<!--
! CDDL HEADER START
!
! The contents of this file are subject to the terms of the
! Common Development and Distribution License, Version 1.0 only
! (the "License"). You may not use this file except in compliance
! with the License.
!
! You can obtain a copy of the license at legal-notices/CDDLv1_0.txt
! See the License for the specific language governing permissions
! and limitations under the License.
!
! When distributing Covered Code, include this CDDL HEADER in each
! file and include the License file at
! legal-notices/CDDLv1_0.txt. If applicable,
! add the following below this CDDL HEADER, with the fields enclosed
! by brackets "[]" replaced with your own identifying information:
! Portions Copyright [yyyy] [name of copyright owner]
!
! CDDL HEADER END
!
! Copyright 2011-2015 ForgeRock AS.
!
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<artifactId>opendj-server-parent</artifactId>
<version>3.0.0-SNAPSHOT</version>
</parent>
<artifactId>opendj-server-legacy</artifactId>
<packaging>jar</packaging>
<name>OpenDJ</name>
<description>
This module provides the OpenDJ server.
</description>
<inceptionYear>2010</inceptionYear>
<repositories>
<repository>
<id>oracle-repository</id>
<name>Oracle Maven Repository</name>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<properties>
<!-- General server-wide properties -->
<!-- Product information properties -->
<shortProductName>OpenDJ</shortProductName>
<lowerCaseProductName>opendj</lowerCaseProductName>
<patchFixIds />
<isDebugBuild>false</isDebugBuild>
<docGuideRefUrl>http://opendj.forgerock.org/opendj-server-legacy/doc/bootstrap/admin-guide/</docGuideRefUrl>
<docGuideAdminUrl>http://opendj.forgerock.org/opendj-server-legacy/doc/bootstrap/admin-guide/</docGuideAdminUrl>
<locales>ca_ES,es,de,fr,ja,ko,pl,zh_CN,zh_TW</locales>
<!-- Dependencies version properties -->
<project.version>3.0.0-SNAPSHOT</project.version>
<i18n.version>1.4.2-SNAPSHOT</i18n.version>
<!-- Other properties -->
<!-- Could be removed once migration to new config framework will be done-->
<old.config.files.path>${project.build.directory}/config/admin/defn/org/opends/server/admin/std</old.config.files.path>
<!-- If we release this project, we need to include the Forgerock binary license -->
<!-- Additional OSGI import package for this module -->
org.forgerock.opendj.*;provide:=true,
org.forgerock.json.*;provide:=true
</properties>
<dependencies>
<!-- ForgeRock libraries -->
<dependency>
<artifactId>opendj-rest2ldap</artifactId>
</dependency>
<dependency>
<artifactId>i18n-slf4j</artifactId>
</dependency>
<dependency>
<artifactId>opendj-config</artifactId>
</dependency>
<dependency>
<artifactId>opendj-server</artifactId>
</dependency>
<dependency>
<artifactId>opendj-cli</artifactId>
</dependency>
<dependency>
<artifactId>forgerock-build-tools</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<artifactId>slf4j-jdk14</artifactId>
</dependency>
<dependency>
<artifactId>json-resource</artifactId>
</dependency>
<dependency>
<artifactId>json-resource-http</artifactId>
</dependency>
<dependency>
<artifactId>chf-http-core</artifactId>
</dependency>
<dependency>
<artifactId>chf-http-servlet</artifactId>
</dependency>
<!-- servlet and mail -->
<dependency>
<version>3.1-b02</version>
</dependency>
<dependency>
<artifactId>grizzly-http-servlet</artifactId>
<version>2.3.16</version>
<exclusions>
<exclusion>
</exclusion>
</exclusions>
</dependency>
<dependency>
<version>1.5.1</version>
</dependency>
<!-- We need to override testNG version to make test works (see OPENDJ-2389) -->
<dependency>
<artifactId>testng</artifactId>
<version>6.0.1</version>
<scope>test</scope>
</dependency>
<dependency>
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<artifactId>mockito-all</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<artifactId>opendj-core</artifactId>
<type>test-jar</type>
<scope>test</scope>
</dependency>
<dependency>
<artifactId>freemarker</artifactId>
<version>2.3.21</version>
<scope>test</scope>
</dependency>
<!-- Databases -->
<dependency>
<artifactId>je</artifactId>
<version>5.0.104</version>
</dependency>
<dependency>
<artifactId>forgerock-persistit-core</artifactId>
<version>4.1.0-SNAPSHOT</version>
</dependency>
</dependencies>
<build>
<resources>
<!-- Main resources -->
<resource>
<filtering>true</filtering>
<excludes>
<exclude>java-stubs/</exclude>
</excludes>
</resource>
<!-- Property files used in test sources -->
<resource>
<filtering>false</filtering>
<includes>
<include>**/*.properties</include>
</includes>
</resource>
<!-- Images for quicksetup must be explicitely copied from sources -->
<resource>
<filtering>false</filtering>
<includes>
<include>**/images/*.gif</include>
<include>**/images/*.png</include>
</includes>
</resource>
<!-- Images for guitools must be explicitely copied from sources -->
<resource>
<filtering>false</filtering>
<includes>
<include>**/images/*.gif</include>
<include>**/images/*.png</include>
</includes>
</resource>
<!-- .plist files for macos must be filtered to include build properties -->
<resource>
<filtering>true</filtering>
<includes>
</includes>
</resource>
<!-- Generation of DynamicConstants class from build properties -->
<resource>
<filtering>true</filtering>
</resource>
</resources>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings only. It
has no influence on the Maven build itself. This section instructs Eclipse's
Maven builder to invoke the antrun plugin for generating the configuration
framework files, e.g. core.manifest, during a *clean* build. Execution
during an incremental build is not supported. -->
<plugin>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<artifactId>maven-antrun-plugin</artifactId>
<versionRange>[1.7,)</versionRange>
<goals>
<goal>run</goal>
</goals>
</pluginExecutionFilter>
<action>
<execute>
<runOnIncremental>false</runOnIncremental>
</execute>
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<!-- Ensure that our usage of the jaxb2-maven-plugin is JDK 8 compatible -->
<artifactId>properties-maven-plugin</artifactId>
<version>1.0-alpha-2</version>
<configuration>
<properties>
<property>
<value>all</value>
</property>
</properties>
</configuration>
<executions>
<execution>
<id>set-additional-system-properties</id>
<goals>
<goal>set-system-properties</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- Clean classes generated outside the build directory -->
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>${basedir}/src</directory>
<includes>
</includes>
<followSymlinks>false</followSymlinks>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<!-- Unpack configuration files from opendj-maven-plugin -->
<!-- This plugin could be removed once the migration to the new config framework will be done -->
<execution>
<id>unpack-config-files</id>
<phase>generate-sources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<artifactId>opendj-maven-plugin</artifactId>
<type>jar</type>
<overWrite>true</overWrite>
<outputDirectory>${project.build.directory}/config/admin/defn/org/opends/server/admin/std</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
<!-- Unpack legacy classes to include them in main jar.
This "hacked" approach is needed since using the maven shade plugin
is too complex with this multi-artefact maven module. -->
<execution>
<id>unpack-legacy-classes</id>
<phase>generate-sources</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<artifactId>opendj-legacy</artifactId>
<type>jar</type>
<overWrite>true</overWrite>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<!-- Generate i18n messages -->
<plugin>
<artifactId>i18n-maven-plugin</artifactId>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>generate-messages</goal>
</goals>
<configuration>
<force>true</force>
<messageFiles>
<!-- Warning: messageFile must contains at least one "/" -->
</messageFiles>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<!-- Copy messages properties files for inclusion in main jar -->
<execution>
<id>copy-l10n-messages</id>
<phase>validate</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<resources>
<resource>
<filtering>false</filtering>
</resource>
</resources>
</configuration>
</execution>
<execution>
<id>copy-l10n-config-messages</id>
<phase>validate</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>${project.build.outputDirectory}/admin/messages/org/opends/server/admin/std/meta</outputDirectory>
<resources>
<resource>
<filtering>false</filtering>
</resource>
</resources>
</configuration>
</execution>
<execution>
<id>copy-guitools-resources</id>
<phase>validate</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<resources>
<resource>
<filtering>false</filtering>
</resource>
</resources>
</configuration>
</execution>
<execution>
<id>copy-quicksetup-resources</id>
<phase>validate</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<resources>
<resource>
<filtering>false</filtering>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>opendj-maven-plugin</artifactId>
<executions>
<execution>
<id>generate-bootstrap-manifest</id>
<goals>
<goal>generate-manifest</goal>
</goals>
<configuration>
<productJarName>${shortProductName}</productJarName>
<supportedLocales>${locales}</supportedLocales>
<excludes>
</excludes>
<additionalJars>
</additionalJars>
</configuration>
</execution>
<execution>
<id>generate-bootstrap-client-manifest</id>
<goals>
<goal>generate-manifest</goal>
</goals>
<configuration>
<productJarName>${shortProductName}</productJarName>
<supportedLocales>${locales}</supportedLocales>
<additionalJars>
</additionalJars>
</configuration>
</execution>
<!-- Generate configuration classes from XML definitions -->
<!-- Leave default lifecycle phase once new config framework migration is done -->
<execution>
<id>generate-config</id>
<!-- <phase>generate-sources</phase> -->
<phase>none</phase>
<goals>
<goal>generate-config</goal>
</goals>
<configuration>
<isExtension>false</isExtension>
</configuration>
</execution>
<!-- Create consolidated schema file for use in upgrade -->
<execution>
<id>creates-base-schema-files</id>
<goals>
<goal>concat</goal>
</goals>
<configuration>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.8</version>
<executions>
<!-- Take into account several sources directories for the build -->
<execution>
<id>main-java-sources</id>
<phase>generate-sources</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
</sources>
</configuration>
</execution>
<!-- Parse version to generate properties (major.version, minor.version, ...) -->
<execution>
<id>parse-version</id>
<goals>
<goal>parse-version</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- Retrieve the SVN revision number and the build timestamp -->
<plugin>
<artifactId>buildnumber-maven-plugin</artifactId>
<version>1.3</version>
<executions>
<execution>
<id>generate-buildnumber</id>
<goals>
<goal>create</goal>
</goals>
<configuration>
<buildNumberPropertyName>buildRevision</buildNumberPropertyName>
<revisionOnScmFailure>-1</revisionOnScmFailure>
</configuration>
</execution>
<execution>
<id>generate-timestamp</id>
<goals>
<goal>create</goal>
</goals>
<configuration>
<format>{0,date,yyyyMMddHHmmss}</format>
<items>
<item>timestamp</item>
</items>
<buildNumberPropertyName>buildDateTime</buildNumberPropertyName>
</configuration>
</execution>
</executions>
</plugin>
<!-- Compile unit tests -->
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<executions>
<execution>
<id>default-testCompile</id>
<goals>
<goal>testCompile</goal>
</goals>
<configuration>
<showDeprecation>false</showDeprecation>
<showWarnings>false</showWarnings>
<testCompilerArgument>-nowarn</testCompilerArgument>
<testExcludes>
</testExcludes>
</configuration>
</execution>
</executions>
</plugin>
<!-- Disable surefire plugin because all tests are run with failsafe plugin -->
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<executions>
<execution>
<id>default-test</id>
<phase>none</phase>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-bundle-plugin</artifactId>
<executions>
<!-- Create opendj-slf4j-adapter manifest -->
<execution>
<id>opendj-slf4j-adapter-manifest</id>
<goals>
<goal>manifest</goal>
</goals>
<configuration>
<instructions>
<!-- Export only slf4j adapter -->
<Import-Package>
</Import-Package>
</instructions>
</configuration>
</execution>
<!-- Create OpenDJ manifest -->
<execution>
<id>opendj-manifest</id>
<goals>
<goal>manifest</goal>
</goals>
<configuration>
<instructions>
<!-- Do not export packages of this module -->
<Export-Package>!*</Export-Package>
<!-- Import je changelog since it is not shipped in the main jar -->
<Import-Package>
</Import-Package>
</instructions>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<!-- Package boostrap jar - contains only a manifest with classpath for the server -->
<execution>
<id>build-bootstrap-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>bootstrap</finalName>
<includes>
<include>nothing</include>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
</archive>
</configuration>
</execution>
<!-- Package boostrap-client jar - contains only a manifest with classpath for clients -->
<execution>
<id>build-bootstrap-client-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>bootstrap-client</finalName>
<includes>
<include>nothing</include>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
</archive>
</configuration>
</execution>
<!-- Package build-tools jar -->
<execution>
<id>create-build-tools-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>build-tools</finalName>
<includes>
</includes>
</configuration>
</execution>
<!-- Package quicksetup jar -->
<execution>
<id>build-quicksetup-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>quicksetup</finalName>
<includes>
<include>**/quicksetup/**</include>
</includes>
</configuration>
</execution>
<!-- Package OpenDJ SL4J Logger Adapter jar -->
<execution>
<id>build-opendj-slf4j-adapter-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>opendj-slf4j-adapter</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
</archive>
</configuration>
</execution>
<!-- Package JE backend and changelog jar -->
<execution>
<id>build-opendj-je-backend-changelog-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>opendj-je-backend-changelog</finalName>
<includes>
</includes>
</configuration>
</execution>
<!-- Build localized jars (one per supported locale) -->
<!-- (is there a way to avoid all these repeated executions ?) -->
<execution>
<id>build-caES-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_ca_ES</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-de-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_de</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-es-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_es</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-fr-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_fr</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-ja-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_ja</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-ko-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_ko</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-pl-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_pl</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-zh-CN-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_zh_CN</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<execution>
<id>build-zh-TW-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}_zh_TW</finalName>
<includes>
</includes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
<!-- Main jar -->
<execution>
<id>default-jar</id>
<phase>package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>${shortProductName}</finalName>
<excludes>
<exclude>*.app/**</exclude>
<exclude>java-stubs/**</exclude>
<exclude>bootstrap/**</exclude>
<exclude>META-INF/**</exclude>
</excludes>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
<index>true</index>
</archive>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<!-- Package the example plugin in a zip -->
<execution>
<id>build-example-package</id>
<phase>prepare-package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<finalName>example-plugin</finalName>
<addMavenDescriptor>false</addMavenDescriptor>
<appendAssemblyId>false</appendAssemblyId>
<attach>false</attach>
<descriptors>
</descriptors>
<formats>
<format>zip</format>
</formats>
</configuration>
</execution>
<!-- Creates the archive folder -->
<execution>
<id>build-opendj-archive</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<finalName>${lowerCaseProductName}</finalName>
<appendAssemblyId>false</appendAssemblyId>
<attach>false</attach>
<descriptors>
</descriptors>
<formats>
<format>dir</format>
</formats>
<archive>
</archive>
</configuration>
</execution>
<!-- Package DSML war -->
<execution>
<id>build-dsml-war</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<finalName>${shortProductName}-${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}-DSML</finalName>
<appendAssemblyId>false</appendAssemblyId>
<addMavenDescriptor>false</addMavenDescriptor>
<descriptors>
</descriptors>
<formats>
<format>war</format>
</formats>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<!-- Temporary solution for configuration classes until migration to new config framework -->
<!-- Change package name and XML namespaces references to match the old config framework -->
<id>configure-config-files</id>
<phase>generate-sources</phase>
<configuration>
<target>
<move todir="${old.config.files.path}">
</move>
<delete dir="${old.config.files.path}/config" />
<replace dir="${old.config.files.path}" token="org.forgerock.opendj.server.config" value="org.opends.server.admin.std" />
<replace dir="${old.config.files.path}" token="http://opendj.forgerock.org/admin" value="http://www.opends.org/admin" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<!-- Temporary solution for configuration classes until migration to new config framework -->
<id>generate-config</id>
<phase>generate-sources</phase>
<configuration>
<target>
<ant antfile="${basedir}/build.xml">
<target name="generateadmin" />
</ant>
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<!-- Copy config.ldif in build dir (needed if snmp config merge is needed) -->
<id>copy-config-ldif</id>
<phase>generate-resources</phase>
<configuration>
<target>
<copy todir="${project.build.directory}/template/config" file="${basedir}/resource/config/config.ldif" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<!-- Generate final zip and attach artefact -->
<execution>
<id>attach-artifact</id>
<phase>package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<zip destfile="${project.build.directory}/package/${shortProductName}-${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.zip">
<zipfileset dir="${project.build.directory}/package/${lowerCaseProductName}" includes="**/*" excludes="bin/*,template/**/*,lib/_client-script.sh,lib/_script-util.sh,lib/_server-script.sh,lib/_mixed-script.sh,setup,uninstall,upgrade,QuickSetup.app/Contents/MacOS/JavaApplicationStub,Uninstall.app/Contents/MacOS/JavaApplicationStub,bin/ControlPanel.app/Contents/MacOS/JavaApplicationStub" filemode="644" dirmode="755" prefix="opendj" />
<zipfileset dir="${project.build.directory}/package/${lowerCaseProductName}" includes="lib/_client-script.sh,lib/_script-util.sh,lib/_server-script.sh,lib/_mixed-script.sh" filemode="755" dirmode="755" prefix="opendj" />
<zipfileset dir="${project.build.directory}/package/${lowerCaseProductName}" includes="bin/*" filemode="755" dirmode="755" prefix="opendj" />
<zipfileset dir="${project.build.directory}/package/${lowerCaseProductName}" includes="setup,uninstall,upgrade,QuickSetup.app/Contents/MacOS/JavaApplicationStub,Uninstall.app/Contents/MacOS/JavaApplicationStub,bin/ControlPanel.app/Contents/MacOS/JavaApplicationStub" filemode="755" dirmode="755" prefix="opendj" />
<zipfileset dir="${project.build.directory}/package/${lowerCaseProductName}" includes="template/**/*" filemode="444" dirmode="744" prefix="opendj" />
</zip>
<attachartifact file="${project.build.directory}/package/${shortProductName}-${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.zip" type="zip" />
</target>
</configuration>
</execution>
</executions>
</plugin>
<!-- Build javadoc -->
<plugin>
<artifactId>javadoc-updater-maven-plugin</artifactId>
<version>1.0.0</version>
<executions>
<execution>
<phase>site</phase>
<goals>
<goal>fixjavadoc</goal>
</goals>
<configuration>
</configuration>
</execution>
</executions>
</plugin>
<!-- Release project -->
<plugin>
<artifactId>maven-release-plugin</artifactId>
<configuration>
<!-- Required for release:perform: the parent pom specifies a value
for "arguments" in the plugin configuration. This prevents command line setting
of the option. -->
</configuration>
</plugin>
<!-- Generate DSML code from XML files -->
<plugin>
<artifactId>jaxb2-maven-plugin</artifactId>
<version>1.6</version>
<executions>
<execution>
<id>prepare-dsml-library</id>
<goals>
<goal>xjc</goal>
</goals>
<configuration>
<target>2.1</target>
<npa>true</npa>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>cobertura-maven-plugin</artifactId>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<!--
Profile to run precommit tasks: checkstyle, copyright (TODO), SVN eol check (TODO),
unit-tests
Tests are not run by default due to running time (average of 8-10 minutes).
-->
<profile>
<id>precommit</id>
<build>
<plugins>
<!-- Enforce Checkstyle -->
<plugin>
<artifactId>maven-checkstyle-plugin</artifactId>
<version>2.14</version>
<executions>
<!-- Disable default from parent -->
<execution>
<id>check-src-and-tests</id>
<phase>none</phase>
<goals>
<goal>checkstyle</goal>
</goals>
</execution>
<execution>
<id>check-src-and-tests-alternative</id>
<configuration>
<excludes>generated/org/opends/server/snmp/**,org/opends/messages/**,**/server/admin/std/**,**/config/meta/**,**/config/client/**,**/config/server/**,**/dsml/protocol/**</excludes>
<configLocation>${project.build.outputDirectory}/org/forgerock/checkstyle/opends-checkstyle.xml</configLocation>
<headerLocation>${project.build.outputDirectory}/org/forgerock/checkstyle/opendj.sourceheader</headerLocation>
<suppressionsLocation>${project.build.outputDirectory}/org/forgerock/checkstyle/unit-test-suppressions.xml</suppressionsLocation>
<includeTestSourceDirectory>true</includeTestSourceDirectory>
<includeResources>false</includeResources>
<!-- Only output errors if we're not expecting any -->
<consoleOutput>${checkstyleFailOnError}</consoleOutput>
<failsOnError>${checkstyleFailOnError}</failsOnError>
</configuration>
<phase>process-test-classes</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<!--
Run unit/integration tests.
A lot of existing tests requires a running server, which is why the tests are
run using failsafe instead of surefire.
It should be possible in the future to separate tests into unit (no server) and
integration (with server), by using respectively surefire and failsafe plugin
to run them, but it will require identifying them.
We could use an "unit" marker in TestNG groups to do so.
-->
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<excludes>
</excludes>
<includes>
<include>**/Test*.java</include>
</includes>
<properties>
<property>
<name>usedefaultlisteners</name>
<value>false</value>
</property>
<property>
<name>listener</name>
</property>
<property>
<name>excludegroups</name>
<value>slow</value>
</property>
<property>
<name>configfailurepolicy</name>
<value>skip</value>
</property>
</properties>
<systemPropertyVariables>
<!-- <jvmarg value="-Dorg.opends.server.snmp.opendmk=${opendmk.lib.dir}" /> -->
</systemPropertyVariables>
<argLine>-server -Xms1024M -Xmx2048M -XX:MaxPermSize=256m</argLine>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<!--
Profile to build SNMP extension.
This profile is only actived when command line contains the 'opendmk.lib.dir'
property that must point to the directory where OpenDMK jars are located.
Example: mvn install -Dopendmk.lib.dir=/path/to/opendmk/jars
-->
<profile>
<id>snmp</id>
<activation>
<property>
</property>
</activation>
<properties>
</properties>
<dependencies>
<dependency>
<groupId>opendmk</groupId>
<artifactId>jdmkrt</artifactId>
<version>1.0</version>
<scope>system</scope>
</dependency>
<dependency>
<groupId>opendmk</groupId>
<artifactId>jdmktk</artifactId>
<version>1.0</version>
<scope>system</scope>
</dependency>
</dependencies>
<build>
<resources>
<resource>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.7</version>
<executions>
<!-- Add snmp source directory and snmp generated directory as sources -->
<execution>
<id>snmp-java-sources</id>
<phase>generate-sources</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<!-- Cleans SNMP directory -->
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>createMibDir</id>
<phase>initialize</phase>
<configuration>
<target>
<delete dir="${snmp.gen.dir}/org/opends/server/snmp" />
<mkdir dir="${snmp.gen.dir}/org/opends/server/snmp" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<!-- Append snmp config to the config.ldif -->
<id>generate-config-ldif</id>
<phase>prepare-package</phase>
<configuration>
<target>
</concat>
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- MIB generation -->
<plugin>
<artifactId>exec-maven-plugin</artifactId>
<version>1.3.2</version>
<executions>
<execution>
<id>mib-generation</id>
<phase>generate-sources</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>java</executable>
<classpathScope>compile</classpathScope>
<arguments>
<argument>-classpath</argument>
<classpath />
<argument>-X:use-display-hint</argument>
<argument>-d</argument>
<argument>-mc</argument>
<argument>-desc</argument>
<argument>-tp</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
<!-- Creates snmp-mib2605 jar file -->
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
<id>create-snmp-jar</id>
<phase>prepare-package</phase>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<finalName>snmp-mib2605</finalName>
<includes>
</includes>
<archive>
<index>true</index>
<addMavenDescriptor>false</addMavenDescriptor>
<manifestEntries>
<Extension-Name>snmp-mib2605</Extension-Name>
<Revision-Number>${buildRevision}</Revision-Number>
</manifestEntries>
</archive>
</configuration>
</execution>
</executions>
</plugin>
<!-- Package the final zip -->
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>build-opendj-archive</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<finalName>${lowerCaseProductName}</finalName>
<descriptors>
</descriptors>
<appendAssemblyId>false</appendAssemblyId>
<formats>
<format>dir</format>
</formats>
<archive>
</archive>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>forgerock-release</id>
<properties>
<!-- Released documentation is published at ForgeRock.com -->
<docGuideRefUrl>https://backstage.forgerock.com/#!/docs/opendj/${project.version}/admin-guide</docGuideRefUrl>
<docGuideAdminUrl>https://backstage.forgerock.com/#!/docs/opendj/${project.version}/admin-guide</docGuideAdminUrl>
</properties>
</profile>
<profile>
<!-- Build man pages -->
<id>man-pages</id>
<build>
<plugins>
<plugin>
<artifactId>opendj-doc-maven-plugin</artifactId>
<executions>
<execution>
<id>generate-man-pages</id>
<goals>
<goal>generate-refentry</goal>
</goals>
<phase>process-classes</phase>
<configuration>
<tools>
<tool>
<name>backup</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>base64</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>control-panel</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>create-rc-script</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>backendstat</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>dbtest</name>
<trailingSectionPaths>
</trailingSectionPaths>
<!-- If no dbtest tool is provided, use this setting
<enabled>false</enabled>
-->
</tool>
<tool>
<name>dsconfig</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>dsjavaproperties</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>dsreplication</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>encode-password</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>export-ldif</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>import-ldif</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldapcompare</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldapdelete</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldapmodify</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldappasswordmodify</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldapsearch</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldif-diff</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldifmodify</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>ldifsearch</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>list-backends</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>make-ldif</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>manage-account</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>manage-tasks</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>rebuild-index</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>restore</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>setup</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>start-ds</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>status</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>stop-ds</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>uninstall</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>upgrade</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
<tool>
<name>verify-index</name>
<trailingSectionPaths>
</trailingSectionPaths>
</tool>
</tools>
</configuration>
</execution>
</executions>
</plugin>
<!-- Format man pages -->
<plugin>
<artifactId>forgerock-doc-maven-plugin</artifactId>
<configuration>
<format>man</format>
</formats>
</configuration>
<executions>
<execution>
<id>build-man-pages</id>
<phase>package</phase>
<goals>
<goal>process</goal>
<goal>build</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>man-pages-sources</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
</descriptors>
</configuration>
</execution>
<execution>
<id>man-pages</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
</descriptors>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<!--
Build the configuration reference, reference documentation source files,
and assemble artifacts from the results.
The artifacts are used when preparing the product documentation.
-->
<id>docs</id>
<build>
<plugins>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-source-dependencies</id>
<phase>prepare-package</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<artifactId>opendj-core</artifactId>
<classifier>sources</classifier>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>opendj-doc-maven-plugin</artifactId>
<!--
Configuration reference generation requires
that opendj-config be on the runtime classpath for the plugin.
It is not enough to declare it as a dependency of this module.
-->
<dependencies>
<dependency>
<artifactId>opendj-config</artifactId>
</dependency>
</dependencies>
<executions>
<execution>
<id>generate-configuration-reference-doc</id>
<phase>compile</phase>
<goals>
<goal>generate-config-ref</goal>
</goals>
</execution>
<execution>
<id>generate-global-acis-table-for-doc</id>
<phase>prepare-package</phase>
<goals>
<goal>generate-global-acis-table</goal>
</goals>
</execution>
<execution>
<id>generate-schema-reference-doc</id>
<phase>prepare-package</phase>
<goals>
<goal>generate-schema-ref</goal>
</goals>
</execution>
<execution>
<id>generate-log-reference-doc</id>
<goals>
<goal>generate-xml-messages-doc</goal>
</goals>
<phase>prepare-package</phase>
<configuration>
<messageFileNames>
<!-- for xxx_yyy.properties generates a log-ref-xxx-yyy.xml file -->
<messageFileName>admin</messageFileName>
<messageFileName>backend</messageFileName>
<messageFileName>config</messageFileName>
<messageFileName>core</messageFileName>
<messageFileName>dsconfig</messageFileName>
<messageFileName>extension</messageFileName>
<messageFileName>logger</messageFileName>
<messageFileName>plugin</messageFileName>
<messageFileName>protocol</messageFileName>
<messageFileName>replication</messageFileName>
<messageFileName>schema</messageFileName>
<messageFileName>task</messageFileName>
<messageFileName>tool</messageFileName>
<messageFileName>utility</messageFileName>
<!-- Ignore following message files as we document only serious errors. -->
<!-- <messageFileName>access_control</messageFileName> -->
<!-- <messageFileName>admin_tool</messageFileName> -->
<!-- <messageFileName>quicksetup.properties</messageFileName> -->
<!-- <messageFileName>runtime_information.properties</messageFileName> -->
<!-- <messageFileName>version.properties</messageFileName> -->
</messageFileNames>
</configuration>
</execution>
<execution>
<id>generate-result-code-doc</id>
<phase>prepare-package</phase>
<goals>
<goal>generate-result-code-doc</goal>
</goals>
<configuration>
<resultCodeSource>${project.build.directory}/dependency/org/forgerock/opendj/ldap/ResultCode.java</resultCodeSource>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>config-ref</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
</descriptors>
</configuration>
</execution>
<execution>
<id>generated-doc-sources</id>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<descriptors>
</descriptors>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<!-- Build the debian package -->
<profile>
<id>package-deb</id>
<properties>
<deb.prefix>/opt/${lowerCaseProductName}</deb.prefix>
<deb.release>1</deb.release>
<deb.maintainer>opendj@forgerock.org</deb.maintainer>
</properties>
<build>
<plugins>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-man-pages</id>
<phase>package</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<artifactId>opendj-server-legacy</artifactId>
<classifier>server-man-pages</classifier>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<!-- Filter deb install and remove scripts -->
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>copy-deb-scripts</id>
<phase>verify</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<resources>
<resource>
<filtering>true</filtering>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<!-- Generates changelog.Debian.gz file -->
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>generate-deb-gzipped-changelog</id>
<phase>verify</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<gzip src="resource/debian/changelog" destfile="${project.build.directory}/deb/changelog.Debian.gz" />
</target>
</configuration>
</execution>
<execution>
<id>gzip-man-pages</id>
<phase>verify</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<apply executable="gzip"><!-- Must we also build these packages on Windows? -->
<arg value="-9" />
<fileset dir="${manpage.dir}" />
</apply>
</target>
</configuration>
</execution>
</executions>
</plugin>
<!-- Generates the deb package -->
<plugin>
<artifactId>jdeb</artifactId>
<version>1.3</version>
<executions>
<execution>
<phase>verify</phase>
<goals>
<goal>jdeb</goal>
</goals>
<configuration>
<deb>${project.build.directory}/deb/${lowerCaseProductName}_${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}-${deb.release}.${maven.build.timestamp}_all.deb</deb>
<dataSet>
<!-- OpenDJ service file -->
<data>
<type>file</type>
<mapper>
<type>perm</type>
<filemode>755</filemode>
</mapper>
</data>
<!-- Debian copyright file in documentation -->
<data>
<type>file</type>
<mapper>
<type>perm</type>
</mapper>
</data>
<!-- Debian changelog file in documentation -->
<data>
<type>file</type>
<mapper>
<type>perm</type>
</mapper>
</data>
<!-- OpenDJ archive documentation files -->
<data>
<type>directory</type>
<mapper>
<type>perm</type>
</mapper>
</data>
<!-- OpenDJ man pages -->
<data>
<type>directory</type>
<mapper>
<type>perm</type>
</mapper>
</data>
<!-- OpenDJ archive files without specific permission -->
<data>
<type>directory</type>
<excludes>**/bat/**, **/*.app/**, **/*.bat*, **/*.exe*, bin/*, template/**/*, lib/*.sh, setup, uninstall, upgrade, legal-notices/**, copyright, README, example-plugin.zip, opendj</excludes>
<mapper>
<type>perm</type>
</mapper>
</data>
<!-- OpenDJ archive files with specific permission -->
<data>
<type>directory</type>
<includes>lib/*.sh, bin/*, setup, uninstall, upgrade</includes>
<mapper>
<type>perm</type>
<filemode>755</filemode>
</mapper>
</data>
<!-- OpenDJ archive template folder -->
<data>
<type>directory</type>
<includes>template/**/*</includes>
<mapper>
<type>perm</type>
<filemode>444</filemode>
</mapper>
</data>
</dataSet>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<!-- Build the RPM package -->
<profile>
<id>package-rpm</id>
<properties>
<rpm.prefix>/opt/${lowerCaseProductName}</rpm.prefix>
</properties>
<build>
<plugins>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-man-pages</id>
<phase>package</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<artifactId>opendj-server-legacy</artifactId>
<classifier>server-man-pages</classifier>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>rpm-maven-plugin</artifactId>
<version>2.0.1</version>
<executions>
<execution>
<id>properties</id>
<phase>verify</phase>
<goals>
<goal>version</goal>
</goals>
</execution>
<execution>
<id>generate-rpm-package</id>
<phase>verify</phase>
<goals>
<goal>rpm</goal>
</goals>
</execution>
</executions>
<configuration>
<summary>${shortProductName}</summary>
<name>${lowerCaseProductName}</name>
<license>CDDL</license>
<url>${docHomepageUrl}</url>
<needarch>noarch</needarch>
<targetOS>linux</targetOS>
<description>
OpenDJ LDAP Server
OpenDJ is an LDAPv3 compliant directory service, developed for the Java
platform, providing a high performance, highly available and secure store
for the identities managed by enterprises. Its easy installation process,
combined with the power of the Java platform makes OpenDJ one of the
simplest and fastest directory servers to deploy and manage.
</description>
<requires>
<require>jre >= 1.7</require>
</requires>
<defineStatements>
<defineStatement>arch noarch</defineStatement>
<defineStatement>_pre ${shortProductName}-${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}</defineStatement>
<defineStatement>__os_install_post %{nil}</defineStatement>
</defineStatements>
<mappings>
<!-- Add directories -->
<mapping>
</mapping>
<mapping>
</mapping>
<mapping>
</mapping>
<mapping>
</mapping>
<mapping>
</mapping>
<mapping>
</mapping>
<mapping>
</mapping>
<mapping>
</mapping>
<!-- Add service script -->
<mapping>
<directoryIncluded>false</directoryIncluded>
<filemode>755</filemode>
<sources>
<source>
</source>
</sources>
</mapping>
<!-- Add executable scripts and libraries -->
<mapping>
<filemode>755</filemode>
<sources>
<source>
<includes>
<include>bin/**</include>
<include>lib/*.sh</include>
<include>setup</include>
<include>uninstall</include>
<include>upgrade</include>
</includes>
<excludes>
<exclude>**/*.exe</exclude>
<exclude>**/*bat</exclude>
<exclude>**/*.app/**</exclude>
<exclude>**/*.app</exclude>
</excludes>
</source>
</sources>
</mapping>
<!-- Add man pages -->
<mapping>
<sources>
<source>
<includes>
<include>**/*.*</include>
</includes>
</source>
</sources>
</mapping>
<!-- Add other files to the rpm -->
<mapping>
<sources>
<source>
<excludes>
<exclude>template/**</exclude>
<exclude>bin/**</exclude>
<exclude>lib/*.sh</exclude>
<exclude>setup</exclude>
<exclude>uninstall</exclude>
<exclude>upgrade</exclude>
<exclude>**/*.exe</exclude>
<exclude>**/*bat</exclude>
<exclude>**/readme</exclude>
<exclude>**/README</exclude>
<exclude>**/*.app/**</exclude>
<exclude>**/*.app</exclude>
</excludes>
</source>
</sources>
</mapping>
<!-- Add template dir -->
<mapping>
<sources>
<source>
</source>
</sources>
</mapping>
</mappings>
<preinstallScriptlet>
<fileEncoding>utf-8</fileEncoding>
</preinstallScriptlet>
<postinstallScriptlet>
<fileEncoding>utf-8</fileEncoding>
</postinstallScriptlet>
<preremoveScriptlet>
<fileEncoding>utf-8</fileEncoding>
</preremoveScriptlet>
<postremoveScriptlet>
<fileEncoding>utf-8</fileEncoding>
</postremoveScriptlet>
<cleanScriptlet>
<fileEncoding>utf-8</fileEncoding>
</cleanScriptlet>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<!-- Build the solaris package -->
<profile>
<id>package-svr4</id>
<build>
<plugins>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-man-pages</id>
<phase>package</phase>
<goals>
<goal>unpack</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<artifactId>opendj-server-legacy</artifactId>
<classifier>server-man-pages</classifier>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>generate-svr4-package</id>
<phase>verify</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<ant antfile="${basedir}/build-svr4.xml">
<target name="svr4" />
</ant>
</target>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>