<?xml version="1.0" encoding="UTF-8"?>
<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/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.blazebit</groupId>
        <artifactId>blaze-persistence-integration</artifactId>
        <version>1.1.1</version>
        <relativePath>../pom.xml</relativePath>
    </parent>

    <artifactId>blaze-persistence-integration-hibernate-4</artifactId>
    <packaging>jar</packaging>

    <name>Blazebit Persistence Integration Hibernate 4</name>

    <dependencies>
        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>blaze-persistence-core-api</artifactId>
        </dependency>
        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>blaze-persistence-integration-hibernate-base</artifactId>
        </dependency>

        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>blaze-apt-utils</artifactId>
            <scope>provided</scope>
        </dependency>
        
        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-entitymanager</artifactId>
            <!-- Minimum version is 4.2.8.Final -->
            <!-- 4.2.15.Final has a bug regarding naming strategies -->
            <version>4.2.14.Final</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>
    
    <build>
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>add-resource</id>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>add-resource</goal>
                        </goals>
                        <configuration>
                            <resources>
                                <resource>
                                    <directory>target/generated/resources</directory>
                                </resource>
                            </resources>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.bsc.maven</groupId>
                <artifactId>maven-processor-plugin</artifactId>
                <executions>
                    <execution>
                        <id>process-resouces</id>
                        <goals>
                            <goal>process</goal>
                        </goals>
                        <phase>generate-resources</phase>
                        <configuration>
                            <outputDirectory>target/generated/resources</outputDirectory>
                            <processors>
                                <!-- list of processors to use -->
                                <processor>com.blazebit.apt.service.ServiceProviderAnnotationProcessor</processor>
                            </processors>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
</project>
