<?xml version="1.0" encoding="UTF-8"?>
<!--
    Copyright 2010 The myBatis Team

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

        http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
-->

<!--
    version: $Id: pom.xml 3497 2010-12-31 20:37:01Z simone.tripodi $
-->
<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">

    <parent>
        <groupId>org.mybatis</groupId>
        <artifactId>mybatis-parent</artifactId>
        <version>8</version>
    </parent>

    <modelVersion>4.0.0</modelVersion>
    <artifactId>mybatis-guice</artifactId>
    <name>MyBatis Guice</name>
    <description>An easy-to-use Google Guice bridge for MyBatis sql mapping framework.</description>
    <version>1.0.0</version>
    <packaging>jar</packaging>

    <contributors>
        <contributor>
            <name>Stephen Friedrich</name>
            <email>stephen.friedrich@fortis-it.eu</email>
        </contributor>
    </contributors>

    <scm>
        <url>scm:svn:http://mybatis.googlecode.com/svn/sub-projects/mybatis-guice/tags/mybatis-guice-1.0.0</url>
        <connection>scm:svn:https://mybatis.googlecode.com/svn/sub-projects/mybatis-guice/tags/mybatis-guice-1.0.0</connection>
        <developerConnection>scm:svn:https://mybatis.googlecode.com/svn/sub-projects/mybatis-guice/tags/mybatis-guice-1.0.0</developerConnection>
    </scm>

    <build>
        <plugins>
            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>jarjar-maven-plugin</artifactId>
                <version>1.3</version>
                <configuration>
                    <excludes>
                        <!--
                         | compile|provided dependencies
                        -->
                        <exclude>org.mybatis:mybatis</exclude>
                        <exclude>com.google.inject:guice</exclude>
                        <exclude>com.google.inject.extensions:guice-multibindings</exclude>
                        <exclude>aopalliance:aopalliance</exclude>
                        <exclude>c3p0:c3p0</exclude>
                        <exclude>commons-dbcp:commons-dbcp</exclude>
                        <exclude>commons-pool:commons-pool</exclude>
                        <!--
                         | test dependencies
                        -->
                        <exclude>junit:junit</exclude>
                        <exclude>hsqldb:hsqldb</exclude>
                        <exclude>log4j:log4j</exclude>
                    </excludes>
                    <rules>
                        <rule>
                            <pattern>org.mybatis.guice.configuration.*</pattern>
                            <result>org.mybatis.guice.configuration.$@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.datasource.dbcp.PerUserDefault*</pattern>
                            <result>org.mybatis.guice.datasource.dbcp.$PerUserDefault@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.datasource.dbcp.PerUserMax*</pattern>
                            <result>org.mybatis.guice.datasource.dbcp.$PerUserMax@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.environment.*</pattern>
                            <result>org.mybatis.guice.environment.$@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.iterables.*</pattern>
                            <result>org.mybatis.guice.iterables.$@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.mappers.*</pattern>
                            <result>org.mybatis.guice.mappers.$@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.session.*</pattern>
                            <result>org.mybatis.guice.session.$@1</result>
                        </rule>
                        <rule>
                            <pattern>org.mybatis.guice.transactional.TransactionalMethodInterceptor</pattern>
                            <result>org.mybatis.guice.transactional.$TransactionalMethodInterceptor</result>
                        </rule>
                        <keep>
                            <pattern>org.mybatis.guice.**</pattern>
                        </keep>
                    </rules>
                </configuration>
                <!--
                 | JarJar all classes before running tests
                -->
                <executions>
                    <execution>
                        <id>jarjar-classes</id>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>jarjar</goal>
                        </goals>
                        <configuration>
                            <input>{classes}</input>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <configuration>
                    <arguments>-Prelease,docbook,bundle,gupload</arguments>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <properties>
        <findbugs.onlyAnalyze>org.mybatis.guice.*</findbugs.onlyAnalyze>
        <clirr.comparisonVersion>1.0.0-RC4</clirr.comparisonVersion>
        <guice.version>2.0</guice.version>
        <gcu.product>Guice</gcu.product>
        <osgi.import>com.mchange.v2.c3p0;resolution:=optional,org.apache.commons.dbcp;resolution:=optional,
        org.apache.commons.dbcp.cpdsadapter;resolution:=optional,org.apache.commons.dbcp.datasources;resolution:=optional,*</osgi.import>
    </properties>

    <dependencies>
        <!-- Provided dependencies -->
        <dependency>
            <groupId>org.mybatis</groupId>
            <artifactId>mybatis</artifactId>
            <version>3.0.4</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.google.inject</groupId>
            <artifactId>guice</artifactId>
            <version>${guice.version}</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.google.inject.extensions</groupId>
            <artifactId>guice-multibindings</artifactId>
            <version>${guice.version}</version>
            <scope>compile</scope>
        </dependency>

        <dependency>
            <groupId>aopalliance</groupId>
            <artifactId>aopalliance</artifactId>
            <version>1.0</version>
            <scope>compile</scope>
        </dependency>

        <dependency>
            <groupId>c3p0</groupId>
            <artifactId>c3p0</artifactId>
            <version>0.9.1.2</version>
            <optional>true</optional>
        </dependency>

        <dependency>
            <groupId>commons-dbcp</groupId>
            <artifactId>commons-dbcp</artifactId>
            <version>1.3</version>
            <optional>true</optional>
        </dependency>

        <!-- Test dependencies -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.8.1</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>hsqldb</groupId>
            <artifactId>hsqldb</artifactId>
            <version>1.8.0.10</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>1.2.15</version>
            <scope>test</scope>
            <exclusions>
                <exclusion>
                    <groupId>com.sun.jdmk</groupId>
                    <artifactId>jmxtools</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>com.sun.jmx</groupId>
                    <artifactId>jmxri</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>javax.jms</groupId>
                    <artifactId>jms</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>javax.mail</groupId>
                    <artifactId>mail</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>junit</groupId>
                    <artifactId>junit</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>oro</groupId>
                    <artifactId>oro</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
    </dependencies>

</project>
