<?xml version="1.0" encoding="UTF-8"?>
<!--

    Copyright (C) 2003-2013 eXo Platform SAS.

    This is free software; you can redistribute it and/or modify it
    under the terms of the GNU Lesser General Public License as
    published by the Free Software Foundation; either version 3 of
    the License, or (at your option) any later version.

    This software is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
    Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public
    License along with this software; if not, write to the Free
    Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
    02110-1301 USA, or see the FSF site: http://www.fsf.org.

-->
<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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <artifactId>plf-public-distributions</artifactId>
    <groupId>org.exoplatform.platform.distributions</groupId>
    <version>5.3.3-RC01</version>
  </parent>
  <artifactId>plf-tomcat-resources</artifactId>
  <packaging>pom</packaging>
  <name>eXo PLF:: Platform Public Distributions - Tomcat Resources</name>
  <dependencies>
    <!-- Logging implementation : http://logback.qos.ch/ -->
    <!-- Is configured from conf/logback.xml -->
    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.tomcat</groupId>
      <artifactId>tomcat</artifactId>
      <type>zip</type>
    </dependency>
    <!-- Additional Tomcat JAR to allow to fix JMX ports. Useful when the server is behind a firewall -->
    <dependency>
      <groupId>org.apache.tomcat</groupId>
      <artifactId>tomcat-catalina-jmx-remote</artifactId>
      <exclusions>
        <exclusion>
          <artifactId>tomcat-coyote</artifactId>
          <groupId>org.apache.tomcat</groupId>
        </exclusion>
        <exclusion>
          <artifactId>tomcat-catalina</artifactId>
          <groupId>org.apache.tomcat</groupId>
        </exclusion>
        <exclusion>
          <artifactId>tomcat-juli</artifactId>
          <groupId>org.apache.tomcat</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <!-- Required by conditional processing in logback -->
    <dependency>
      <groupId>org.codehaus.janino</groupId>
      <artifactId>janino</artifactId>
    </dependency>
    <!-- PLF Shared resources -->
    <dependency>
      <groupId>org.exoplatform.platform.distributions</groupId>
      <artifactId>plf-packaging-resources</artifactId>
      <type>zip</type>
    </dependency>
    <!-- GateIn Container Integration Servlet -->
    <dependency>
      <groupId>org.exoplatform.platform.distributions</groupId>
      <artifactId>plf-tomcat-integration-webapp</artifactId>
      <type>war</type>
    </dependency>
    <dependency>
      <groupId>org.exoplatform.platform.distributions</groupId>
      <artifactId>plf-tomcat-integration-webapp</artifactId>
      <type>pom</type>
    </dependency>
    <!-- Tomcat listener to create portlet containers -->
    <dependency>
      <groupId>org.exoplatform.platform.distributions</groupId>
      <artifactId>plf-tomcat-pc-creator-listener</artifactId>
    </dependency>
    <!-- Required by logback for colorized console on windows -->
    <dependency>
      <groupId>org.fusesource.jansi</groupId>
      <artifactId>jansi</artifactId>
    </dependency>
    <!-- Embedded database - for dev and demos only -->
    <dependency>
      <groupId>org.hsqldb</groupId>
      <artifactId>hsqldb</artifactId>
    </dependency>
    <!-- Use SLF4J and not commons-logging -->
    <!-- commons-logging must be removed from dependencies -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>jcl-over-slf4j</artifactId>
    </dependency>
    <!-- Redirect everything from JUL to SLF4J -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>jul-to-slf4j</artifactId>
    </dependency>
    <!-- Use SLF4J and not log4j -->
    <!-- log4j must be removed from dependencies -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>log4j-over-slf4j</artifactId>
    </dependency>
    <!-- SLF4J API -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>
    <!-- PLF-6409: Required by Liquibase to use slf4j -->
    <dependency>
      <groupId>com.mattbertolini</groupId>
      <artifactId>liquibase-slf4j</artifactId>
    </dependency>
    <!-- PLF-6409: Required by Liquibase to not generate error -->
    <dependency>
      <groupId>org.yaml</groupId>
      <artifactId>snakeyaml</artifactId>
    </dependency>
  </dependencies>
  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-assembly-plugin</artifactId>
        <executions>
          <execution>
            <id>project-resources-zip</id>
            <phase>prepare-package</phase>
            <goals>
              <goal>single</goal>
            </goals>
            <configuration>
              <descriptorRefs>
                <descriptorRef>project-resources-zip</descriptorRef>
              </descriptorRefs>
            </configuration>
          </execution>
        </executions>
        <dependencies>
          <dependency>
            <groupId>org.exoplatform.platform.distributions</groupId>
            <artifactId>plf-assemblies</artifactId>
            <version>${project.version}</version>
          </dependency>
        </dependencies>
      </plugin>
    </plugins>
  </build>
  <profiles>
    <profile>
      <id>exo-release</id>
      <build>
        <plugins>
          <!-- Validate wellformedness of (almost) all XML files -->
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>xml-maven-plugin</artifactId>
            <executions>
              <execution>
                <id>validate-xml-files</id>
                <goals>
                  <goal>validate</goal>
                </goals>
              </execution>
            </executions>
            <configuration>
              <validationSets>
                <validationSet>
                  <dir>src/main/resources</dir>
                  <includes>
                    <include>**/*.xml</include>
                  </includes>
                  <excludes>
                    <!-- This is a template not valid by default -->
                    <exclude>**/*.template.xml</exclude>
                  </excludes>
                </validationSet>
              </validationSets>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
