<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>
    <artifactId>jain-slee-annotations-processor</artifactId>
    <name>JAIN SLEE 1.1 Annotation Processor</name>

    <parent>
        <groupId>mobi.mofokom.slee</groupId>
        <artifactId>jain-slee-annotations-parent</artifactId>
        <version>1.0.4</version>
    </parent>

    <properties>
        <maven.compiler.source>1.8</maven.compiler.source>
        <maven.compiler.target>1.8</maven.compiler.target>
        <version.aspectj>1.9.19</version.aspectj> 
    </properties>

    <dependencies>
        <dependency>
            <groupId>javax.slee</groupId>
            <artifactId>jainslee-api</artifactId>
            <version>1.1</version>
            <scope>provided</scope>
            <exclusions>
                <exclusion>
                    <groupId>javax.resource</groupId>
                    <artifactId>connector</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>javax.transaction</groupId>
                    <artifactId>jta</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.10</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>xalan</groupId>
            <artifactId>xalan</artifactId>
            <version>2.7.1</version>
            <exclusions>
                <exclusion>
                    <artifactId>xml-apis</artifactId>
                    <groupId>xml-apis</groupId>
                </exclusion>
            </exclusions>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>mobi.mofokom.javax.slee</groupId>
            <artifactId>jain-slee-annotations</artifactId>
            <version>${project.version}</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>javax.ejb</groupId>
            <artifactId>ejb-api</artifactId>
            <version>3.0</version>
            <type>jar</type>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>xml-resolver</groupId>
            <artifactId>xml-resolver</artifactId>
            <version>1.2</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>1.18.12</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-all</artifactId>
            <version>2.0.2-beta</version>
            <scope>test</scope>
        </dependency>
        
        <dependency>
            <groupId>org.aspectj</groupId>
            <artifactId>aspectjweaver</artifactId>
            <version>${version.aspectj}</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>org.aspectj</groupId>
            <artifactId>aspectjrt</artifactId>
            <version>${version.aspectj}</version>
            <scope>runtime</scope>
        </dependency>
        <dependency>
            <groupId>javax.annotation</groupId>
            <artifactId>jsr250-api</artifactId>
            <version>1.0</version>
            <type>jar</type>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-jdk14</artifactId>
            <version>1.7.6</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>jain-slee-annotations-examples</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>
    </dependencies>
    <build>
        <defaultGoal>install</defaultGoal>
        <resources>
            <resource>
                <filtering>true</filtering>
                <directory>${basedir}/src/main/resources</directory>
            </resource>
           
        </resources>
        <testResources>
            <testResource>
                <directory>${basedir}/src/test/aspect</directory>
            </testResource>
        </testResources>
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>xml-maven-plugin</artifactId>
                <version>1.0-beta-3</version>
                <executions>
                    <execution>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>validate</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <validationSets>
                        <validationSet>
                            <dir>${basedir}/src/main/resources/</dir>
                            <includes>
                                <include>
                                    **/*.xml
                                </include>
                                <include>
                                    **/*.xslt
                                </include>
                            </includes>
                        </validationSet>
                    </validationSets>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>xsltc-maven-plugin</artifactId>
                <version>1.1</version>
                <executions>
                    <execution>
                        <phase>compile</phase>
                        <goals>
                            <goal>compile</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <outputDirectory>target/classes/</outputDirectory>
                    <packageName>mobi.mofokom.javax.slee.translet</packageName>
                    <transformerFactoryClass>org.apache.xalan.xsltc.trax.TransformerFactoryImpl</transformerFactoryClass>
                    <stylesheets>
                        <stylesheet>src/main/resources/id.xslt</stylesheet>
                        <stylesheet>src/main/resources/common.xslt</stylesheet>
                        <stylesheet>src/main/resources/aspect.xslt</stylesheet>
                        <stylesheet>src/main/resources/annotations.xslt</stylesheet>
                        <stylesheet>src/main/resources/service.xslt</stylesheet>
                        <stylesheet>src/main/resources/event-jar.xslt</stylesheet>
                        <stylesheet>src/main/resources/sbb-jar.xslt</stylesheet>
                        <stylesheet>src/main/resources/resource-adaptor-jar.xslt</stylesheet>
                        <stylesheet>src/main/resources/resource-adaptor-type-jar.xslt</stylesheet>
                        <stylesheet>src/main/resources/profile-spec-jar.xslt</stylesheet>
                    </stylesheets>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <executions>
                    <execution>
                        <id>default-jar</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <phase>package</phase>
                        <configuration>
                            <attach>true</attach>
                            <!--
            <excludes>
                <exclude>**/*.xslt</exclude>
            </excludes>
                            -->
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>3.1.1</version>
                <executions>
                    <execution>
                        <id>copy-deps</id>
                        <phase>install</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>
                        <configuration>
                            <includeScope>runtime</includeScope>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <configuration />
            </plugin>

            <!--
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>3.1.1</version>
                    <executions>
                        <execution>
                            <id>unpack</id>
                            <phase>generate-test-sources</phase>
                            <goals>
                                <goal>unpack</goal>
                            </goals>
                            <configuration>
                                <artifactItems>
                                    <artifactItem>
                                        <groupId>org.mobicents.servers.jainslee.api</groupId>
                                        <artifactId>jain-slee-11-ext</artifactId>
                                        <version>1.0.0-SNAPSHOT</version>
                                        <classifier>sources</classifier>
                                        <type>jar</type>
                                        <overWrite>true</overWrite>
                                        <outputDirectory>${project.build.directory}/generated-test-sources/unpack</outputDirectory>
                                        <includes>**/*.java</includes>
                                    </artifactItem>
                                </artifactItems>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>build-helper-maven-plugin</artifactId>
                    <version>3.1.0</version>
                    <executions>
                        <execution>
                            <id>add-test-source</id>
                            <phase>generate-test-sources</phase>
                            <goals>
                                <goal>add-test-source</goal>
                            </goals>
                            <configuration>
                                <sources>
                                    <source>${project.build.directory}/generated-test-sources/unpack</source>
                                </sources>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
            -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.1</version>
                <executions>
                    <execution>
                        <id>default-compile</id>
                        <goals>
                            <goal>compile</goal>
                        </goals>
                        <configuration>
                            <proc>none</proc>
                            <useIncrementalCompilation>false</useIncrementalCompilation>
                        </configuration>
                    </execution>
                    <execution>
                        <id>default-testCompile</id>
                        <phase>test-compile</phase>
                        <goals>
                            <goal>testCompile</goal>
                        </goals>
                        <configuration>
                            <skip>true</skip>
                            <proc>none</proc>
                            <annotationProcessorPaths>
                                <!--
                                <path>
                                    <groupId>${project.groupId}</groupId>
                                    <artifactId>${project.artifactId}</artifactId>
                                    <version>${project.version}</version>
                                </path>    
                                                -->
                                <path>
                                    <groupId>org.projectlombok</groupId>
                                    <artifactId>lombok</artifactId>
                                    <version>1.18.12</version>
                                </path>
                            </annotationProcessorPaths>
                            <!--
                            <compilerArgs>
                                <arg>-Anobinary=true</arg>
                                <arg>-Adebug</arg>
                                <arg>-Anofail</arg>
                            </compilerArgs>
                                        -->
                        </configuration>
                    </execution>
                </executions>
                <configuration>
                    <debug>true</debug>
                </configuration>
            </plugin>
            <plugin>
                <!--
                <groupId>org.codehaus.mojo</groupId>
                <groupId>com.nickwongdev</groupId>
                <version>1.12.6</version>
                <artifactId>aspectj-maven-plugin</artifactId>
                <version>1.14.0</version>
                -->
                <groupId>dev.aspectj</groupId>
                <artifactId>aspectj-maven-plugin</artifactId>
                <version>1.13.M3</version>
                <executions>
                    <execution>
                        <id>test-compile</id>
                        <phase>test-compile</phase>
                        <goals>
                            <goal>test-compile</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <forceAjcCompile>true</forceAjcCompile>
                    <source>1.8</source>
                    <target>1.8</target>
                    <complianceLevel>1.8</complianceLevel>
                    <showWeaveInfo>false</showWeaveInfo>
                    <verbose>false</verbose>
                    <XnoInline>true</XnoInline>
                    <!--
<proc>none</proc>
                    -->
                    <additionalCompilerArgs>-Anobinary=false, -Adebug=true, -Anofail</additionalCompilerArgs>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>org.aspectj</groupId>
                        <artifactId>aspectjtools</artifactId>
                        <version>${version.aspectj}</version>
                    </dependency>
                </dependencies>
            </plugin>
        </plugins>
    </build>
</project>
