<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>hu.blackbelt.osgi.utils</groupId>
    <artifactId>hu.blackbelt.osgi.utils.parent</artifactId>
    <version>1.0.12</version>
  </parent>
  <groupId>hu.blackbelt.osgi.utils</groupId>
  <artifactId>features</artifactId>
  <version>1.0.12</version>
  <packaging>feature</packaging>
  <name>OSGi utils karaf features</name>
  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
    </license>
  </licenses>
  <dependencies>
    <dependency>
      <groupId>org.apache.karaf.features</groupId>
      <artifactId>framework</artifactId>
      <version>${karaf-version}</version>
      <type>kar</type>
      <scope>runtime</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.karaf.features</groupId>
      <artifactId>standard</artifactId>
      <version>${karaf-version}</version>
      <type>xml</type>
      <classifier>features</classifier>
      <scope>runtime</scope>
    </dependency>
    <dependency>
      <groupId>hu.blackbelt.karaf.features</groupId>
      <artifactId>google-features</artifactId>
      <version>${google-karaf-features-version}</version>
      <type>xml</type>
      <classifier>features</classifier>
      <scope>runtime</scope>
    </dependency>
  </dependencies>
  <build>
    <resources>
      <resource>
        <targetPath>${project.build.directory}/feature</targetPath>
        <filtering>true</filtering>
        <directory>${project.basedir}/src/main/feature</directory>
      </resource>
    </resources>
    <plugins>
      <plugin>
        <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>
        <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:hu.blackbelt.karaf.features/google-features/${google-karaf-features-version}/xml/features</descriptor>
                <descriptor>file:${project.build.directory}/feature/feature.xml</descriptor>
              </descriptors>
              <distribution>org.apache.karaf.features:framework</distribution>
              <javase>11</javase>
              <framework>
                <feature>framework</feature>
                <feature>shell-compat</feature>
              </framework>
              <features>
                <feature>osgi-utils</feature>
              </features>
            </configuration>
          </execution>
        </executions>
        <configuration>
          <enableGeneration>true</enableGeneration>
          <aggregateFeatures>true</aggregateFeatures>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>
