<?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>hu.blackbelt.karaf.features</groupId>
        <artifactId>jdbc</artifactId>
        <version>1.0.2</version>
        <relativePath>../</relativePath>
    </parent>
    <artifactId>jdbc-features</artifactId>
    <packaging>feature</packaging>
    <name>JDBC Drivers Karaf features</name>

    <build>
        <resources>
            <resource>
                <directory>${project.basedir}/src/main/feature</directory>
                <filtering>true</filtering>
                <targetPath>${project.build.directory}/feature</targetPath>
            </resource>
        </resources>
            
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-resources-plugin</artifactId>
                <version>3.0.2</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>resources</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.karaf.tooling</groupId>
                <artifactId>karaf-maven-plugin</artifactId>
                <extensions>true</extensions>
                <configuration>
                    <enableGeneration>true</enableGeneration>
                    <aggregateFeatures>true</aggregateFeatures>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.karaf.tooling</groupId>
                <artifactId>karaf-maven-plugin</artifactId>
                <extensions>true</extensions>
                <configuration>
                    <enableGeneration>true</enableGeneration>
                    <aggregateFeatures>true</aggregateFeatures>
                </configuration>
                <executions>
                    <execution>
                        <id>feature-verify</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>verify</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>mvn:org.apache.karaf.features/framework/${karaf-version}/xml/features</descriptor>
                                <descriptor>mvn:org.apache.karaf.features/standard/${karaf-version}/xml/features</descriptor>
                                <descriptor>mvn:org.apache.karaf.features/enterprise/${karaf-version}/xml/features</descriptor>
                                <descriptor>file:${project.build.directory}/feature/feature.xml</descriptor>
                            </descriptors>
                            <distribution>org.apache.karaf.features:framework</distribution>
                            <javase>1.8</javase>
                            <framework>
                                <feature>framework</feature>
                                <feature>shell-compat</feature>
                            </framework>
                            <features>
                                <feature>jdbc-h2</feature>
                                <feature>jdbc-postgresql</feature>
                                <feature>jdbc-oracle_11_2</feature>
                                <feature>jdbc-oracle_12_1</feature>
                                <feature>jdbc-oracle_12_2</feature>
                                <feature>jdbc-oracle_18_3</feature>
                                <feature>jdbc-oracle</feature>
                                <feature>jdbc-hsqldb_2_3</feature>
                                <feature>jdbc-hsqldb_2_4</feature>
                                <feature>jdbc-hsqldb_2_5</feature>
                                <feature>jdbc-hsqldb_2_6</feature>
                                <feature>jdbc-hsqldb</feature>
                            </features>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>
    <dependencies>
        <dependency>
            <groupId>org.apache.karaf.features</groupId>
            <artifactId>framework</artifactId>
            <type>kar</type>
            <scope>runtime</scope>
            <version>${karaf-version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.karaf.features</groupId>
            <artifactId>standard</artifactId>
            <classifier>features</classifier>
            <type>xml</type>
            <scope>runtime</scope>
            <version>${karaf-version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.karaf.features</groupId>
            <artifactId>enterprise</artifactId>
            <classifier>features</classifier>
            <type>xml</type>
            <scope>runtime</scope>
            <version>${karaf-version}</version>
        </dependency>        
    </dependencies>
</project>
