mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Gaetan Boismal
08.57.2016 60986e6b7152e0e2985a7ae1fcad5eb164d1832b
OPENDJ-2825 Fix OEM Archive build

Fix OEM bootstrap.jar and bootstrap-client.jar generation
(opendj jars were still in camel case and in bootstrap-client there was a dependency on jul-to-slf4j jar).
Try to factorize code as much as possible to avoid such issues in future.
3 files modified
99 ■■■■ changed files
opendj-packages/opendj-zip/opendj-zip-oem/pom.xml 45 ●●●● patch | view | raw | blame | history
opendj-server-legacy/pom.xml 15 ●●●● patch | view | raw | blame | history
pom.xml 39 ●●●●● patch | view | raw | blame | history
opendj-packages/opendj-zip/opendj-zip-oem/pom.xml
@@ -41,7 +41,6 @@
            ${product.name.lowercase}/lib/opendj-je-backend.jar,
            ${product.name.lowercase}/legal-notices/THIRDPARTYREADME.txt
        </oem.file.exclusion.list>
        <product.locales>ca_ES,es,de,fr,ja,ko,pl,zh_CN,zh_TW</product.locales>
        <product.archive.name>${product.name.lowercase}-oem-${project.version}</product.archive.name>
    </properties>
@@ -61,50 +60,20 @@
                </exclusion>
            </exclusions>
        </dependency>
        <!-- Override scope for org.slf4j:slf4j-jdk14 to have it in the bootstrap-client.jar -->
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-jdk14</artifactId>
        </dependency>
    </dependencies>
    <build>
        <plugins>
            <!-- Generates bootstrap.jar and bootstrap-client.jar for OEM archive edition -->
            <plugin>
                <groupId>org.forgerock.opendj</groupId>
                <artifactId>opendj-maven-plugin</artifactId>
                <version>${project.version}</version>
                <configuration>
                    <productJarName>${product.name}</productJarName>
                    <supportedLocales>${product.locales}</supportedLocales>
                </configuration>
                <executions>
                    <execution>
                        <id>generate-bootstrap-manifest</id>
                        <goals>
                            <goal>generate-manifest</goal>
                        </goals>
                        <configuration>
                            <classPathProperty>classpath.bootstrap</classPathProperty>
                            <excludes>
                                <exclude>org.slf4j:slf4j-jdk14</exclude>
                                <exclude>org.forgerock.opendj:opendj-server-legacy</exclude>
                            </excludes>
                            <additionalJars>
                                <additionalJar>opendj-slf4j-adapter.jar</additionalJar>
                            </additionalJars>
                        </configuration>
                    </execution>
                    <execution>
                        <id>generate-bootstrap-client-manifest</id>
                        <goals>
                            <goal>generate-manifest</goal>
                        </goals>
                        <configuration>
                            <classPathProperty>classpath.bootstrap-client</classPathProperty>
                            <excludes>
                                <exclude>org.forgerock.opendj:opendj-server-legacy</exclude>
                            </excludes>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
opendj-server-legacy/pom.xml
@@ -56,7 +56,6 @@
    <docWikiUrl>http://opendj.forgerock.org/docs.html</docWikiUrl>
    <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>
    <!-- Other properties -->
    <maven.build.timestamp.format>yyyyMMdd</maven.build.timestamp.format>
@@ -452,6 +451,7 @@
      <plugin>
        <groupId>org.forgerock.opendj</groupId>
        <artifactId>opendj-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>generate-bootstrap-manifest</id>
@@ -459,30 +459,19 @@
              <goal>generate-manifest</goal>
            </goals>
            <configuration>
              <classPathProperty>classpath.bootstrap</classPathProperty>
              <productJarName>${product.name.lowercase}</productJarName>
              <supportedLocales>${locales}</supportedLocales>
              <excludes>
                <exclude>org.slf4j:slf4j-jdk14</exclude>
              </excludes>
              <additionalJars>
                 <additionalJar>opendj-slf4j-adapter.jar</additionalJar>
                 <additionalJar>opendj-je-backend.jar</additionalJar>
              </additionalJars>
            </configuration>
          </execution>
          <execution>
            <id>generate-bootstrap-client-manifest</id>
            <goals>
              <goal>generate-manifest</goal>
            </goals>
            <configuration>
              <classPathProperty>classpath.bootstrap-client</classPathProperty>
              <productJarName>${product.name.lowercase}</productJarName>
              <supportedLocales>${locales}</supportedLocales>
              <excludes>
                <exclude>org.slf4j:jul-to-slf4j</exclude>
              </excludes>
              <additionalJars>
                 <additionalJar>opendj-je-backend.jar</additionalJar>
              </additionalJars>
pom.xml
@@ -38,6 +38,7 @@
    <properties>
        <product.name>OpenDJ</product.name>
        <product.name.lowercase>opendj</product.name.lowercase>
        <product.locales>ca_ES,es,de,fr,ja,ko,pl,zh_CN,zh_TW</product.locales>
        <localized.jars.classifier>i18n</localized.jars.classifier>
        <site.distribution.url>
@@ -411,6 +412,44 @@
                    <groupId>org.forgerock.opendj</groupId>
                    <artifactId>opendj-maven-plugin</artifactId>
                    <version>${project.version}</version>
                    <!-- bootstrap and bootstrap-clinet MANIFEST.MF files generation. -->
                    <configuration>
                        <productJarName>${product.name.lowercase}</productJarName>
                        <supportedLocales>${product.locales}</supportedLocales>
                    </configuration>
                    <executions>
                        <execution>
                            <id>generate-bootstrap-manifest</id>
                            <goals>
                                <goal>generate-manifest</goal>
                            </goals>
                            <configuration>
                                <classPathProperty>classpath.bootstrap</classPathProperty>
                                <excludes>
                                    <exclude>org.slf4j:slf4j-jdk14</exclude>
                                    <exclude>org.forgerock.opendj:opendj-server-legacy</exclude>
                                </excludes>
                                <additionalJars>
                                    <additionalJar>opendj-slf4j-adapter.jar</additionalJar>
                                </additionalJars>
                            </configuration>
                        </execution>
                        <execution>
                            <id>generate-bootstrap-client-manifest</id>
                            <goals>
                                <goal>generate-manifest</goal>
                            </goals>
                            <configuration>
                                <classPathProperty>classpath.bootstrap-client</classPathProperty>
                                <excludes>
                                    <exclude>org.slf4j:jul-to-slf4j</exclude>
                                    <exclude>org.forgerock.opendj:opendj-server-legacy</exclude>
                                </excludes>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
                <plugin>