<?xml version="1.0"?>
<!--
/*************************************************************************
 *
 * ADOBE CONFIDENTIAL
 * __________________
 *
 *  Copyright 2011 Adobe Systems Incorporated
 *  All Rights Reserved.
 *
 * NOTICE:  All information contained herein is, and remains
 * the property of Adobe Systems Incorporated and its suppliers,
 * if any.  The intellectual and technical concepts contained
 * herein are proprietary to Adobe Systems Incorporated and its
 * suppliers and are protected by trade secret or copyright law.
 * Dissemination of this information or reproduction of this material
 * is strictly forbidden unless prior written permission is obtained
 * from Adobe Systems Incorporated.
 **************************************************************************/
-->
<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>
    <!-- ======================================================================= -->
    <!-- P A R E N T                                                             -->
    <!-- ======================================================================= -->
    <parent>
        <groupId>com.adobe.granite</groupId>
        <artifactId>parent</artifactId>
        <version>16</version>
        <relativePath />
    </parent>

    <!-- ======================================================================= -->
    <!-- P R O J E C T                                                           -->
    <!-- ======================================================================= -->
    <groupId>com.adobe.granite</groupId>
    <artifactId>com.adobe.granite.crxde-support</artifactId>
    <packaging>bundle</packaging>
    <name>Day CRXDE Support</name>
    <version>2.3.12</version>

    <description>
        This module provides services for the CRX integrated development environment.
    </description>
    
    <scm>
        <connection>scm:svn:http://svn.day.com/repos/granite/tags/com.adobe.granite.crxde-support-2.3.12</connection>
        <developerConnection>scm:svn:http://svn.day.com/repos/granite/tags/com.adobe.granite.crxde-support-2.3.12</developerConnection>
        <url>http://svn.day.com/repos/granite/tags/com.adobe.granite.crxde-support-2.3.12</url>
    </scm>
    
    <!-- ======================================================================= -->
    <!-- B U I L D                                                               -->
    <!-- ======================================================================= -->
    <build>
        <resources>
            <resource>
                <directory>${basedir}/src/main/resources</directory>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-scr-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.sling</groupId>
                <artifactId>maven-sling-plugin</artifactId>
                <configuration>
                    <slingUrlSuffix>/libs/granite/crxde/install/</slingUrlSuffix>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <extensions>true</extensions>
                <configuration>
                    <instructions>
                      <!-- We need this for compatibility -->
                        <Bundle-SymbolicName>com.day.crx.crxde-support</Bundle-SymbolicName>
                        <Embed-Dependency>
                            bndlib,
                            org.apache.felix.scr.generator,
                            org.apache.felix.scr.annotations,
                            asm-all,
                            qdox
                        </Embed-Dependency>
                        <Embed-Transitive>false</Embed-Transitive>
                        <!-- Downgrade dependency versions to avoid problems
                             when upgrading CRX in CQ5.3 (bug #29010).
                             TODO: Upgrade also the Jackrabbit bundles -->
                        <Import-Package>
                            org.apache.jackrabbit.commons;version=2.0.0,
                            org.apache.jackrabbit.commons.iterator;version=2.0.0,
                            org.apache.jackrabbit.util;version=2.0.0,
                            !junit.*,
                            !org.apache.tools.ant.*,
                            *
                        </Import-Package>
                        <Private-Package>
                            com.day.crx.ide.*
                        </Private-Package>
                    </instructions>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <executions>
                    <execution>
                        <id>copy-dependencies</id>
                        <phase>package</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>
                        <configuration>
                            <includeArtifactIds>bndlib,org.apache.felix.scr.generator,org.apache.felix.scr.annotations,asm-all,qdox</includeArtifactIds>
                            <outputDirectory>${project.build.directory}/embedded-libs</outputDirectory>
                            <overWriteReleases>false</overWriteReleases>
                            <overWriteSnapshots>false</overWriteSnapshots>
                            <overWriteIfNewer>true</overWriteIfNewer>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>

    <!-- ====================================================================== -->
    <!-- R E P O R T I N G                                                      -->
    <!-- ====================================================================== -->
    <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <configuration>
                    <skip>true</skip>
                </configuration>
            </plugin>
        </plugins>
    </reporting>

    <!-- ====================================================================== -->
    <!-- D E P E N D E N C I E S                                                -->
    <!-- ====================================================================== -->
    <dependencies>
        <!-- servlet API -->
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
        </dependency>
        <dependency>
            <groupId>javax.jcr</groupId>
            <artifactId>jcr</artifactId>
        </dependency>

        <!-- CRX related -->
        <dependency>
            <groupId>com.day.crx</groupId>
            <artifactId>crx-scm-integration</artifactId>
            <version>2.3.11</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.jackrabbit</groupId>
            <artifactId>jackrabbit-jcr-commons</artifactId>
            <version>2.3.0</version>
            <scope>provided</scope>
        </dependency>

        <!-- filevault -->
        <dependency>
            <groupId>com.day.jcr.vault</groupId>
            <artifactId>com.day.jcr.vault</artifactId>
            <version>2.3.16</version>
            <scope>provided</scope>
        </dependency>

        <!-- for logging -->
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
        </dependency>

        <!-- Sling related -->
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.api</artifactId>
            <version>2.2.0</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.settings</artifactId>
            <version>1.0.2</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.jcr.api</artifactId>
            <version>2.1.0</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.commons.json</artifactId>
            <version>2.0.6</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.jcr.compiler</artifactId>
            <version>2.0.2</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.commons.compiler</artifactId>
            <version>2.0.2</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.sling</groupId>
            <artifactId>org.apache.sling.commons.classloader</artifactId>
            <version>1.2.2</version>
            <scope>provided</scope>
        </dependency>

        <!-- SCR plugin to generate descriptors -->
        <dependency>
            <groupId>org.apache.felix</groupId>
            <artifactId>org.apache.felix.scr.generator</artifactId>
            <version>1.1.2</version>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>org.apache.felix</groupId>
            <artifactId>org.apache.felix.scr.annotations</artifactId>
            <version>1.6.0</version>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>asm</groupId>
            <artifactId>asm-all</artifactId>
            <version>3.1</version>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>com.thoughtworks.qdox</groupId>
            <artifactId>qdox</artifactId>
            <version>1.12</version>
            <optional>true</optional>
        </dependency>

        <!-- OSGi related -->
        <dependency>
            <groupId>org.apache.felix</groupId>
            <artifactId>org.osgi.core</artifactId>
            <version>1.2.0</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.felix</groupId>
            <artifactId>org.osgi.compendium</artifactId>
            <version>1.2.0</version>
            <scope>provided</scope>
            <exclusions>
                <exclusion>
                    <groupId>org.apache.felix</groupId>
                    <artifactId>javax.servlet</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>org.apache.felix</groupId>
                    <artifactId>org.osgi.foundation</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

        <!-- commons -->
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>1.4</version>
            <scope>provided</scope>
        </dependency>

        <!-- bnd -->
        <dependency>
            <groupId>biz.aQute</groupId>
            <artifactId>bndlib</artifactId>
            <version>0.0.323</version>
        </dependency>

        <!-- for testing -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-simple</artifactId>
        </dependency>
    </dependencies>
    
    <!-- TODO: Add to Central -->
    <repositories>
        <repository>
            <id>aQute</id>
            <url>http://www.aQute.biz/repo</url>
        </repository>
    </repositories>
</project>
