<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>

    <groupId>com.gengoai</groupId>
    <artifactId>jcrfsuite</artifactId>
    <version>0.6.1</version>
    <name>Crfsuite for Java</name>
    <description>
        This project is repackaging of JCrfsuite to remove the native class loading functionality which causes illegal reflective access errors in newer versions of Java.
        Jcrfsuite is a Java interface for crfsuite, a fast implementation of Conditional Random Fields,
        using SWIG.
    </description>
    <packaging>jar</packaging>
    <url>http://maven.apache.org</url>

    <licenses>
        <license>
            <name>Apache License 2.0</name>
            <comments>jcrfsuite is released under the Apache License 2.0</comments>
        </license>
        <license>
            <name>BSD License</name>
            <comments>crfsuite's license</comments>
        </license>
    </licenses>

    <developers>
        <developer>
            <name>David B. Bracewell (Repackaging developer)</name>
            <email>david@gengoai.com</email>
            <organization>GengoAI</organization>
            <organizationUrl>http://www.gengoai.com</organizationUrl>
        </developer>

        <developer>
            <id>vinhkhuc</id>
            <name>Vinh Khuc (Original Jcrfsuite developer)</name>
            <url>http://github.com/vinhkhuc</url>
            <roles>
                <role>architect</role>
                <role>developer</role>
            </roles>
        </developer>

        <developer>
            <id>juharris</id>
            <name>Justin Harris (Original Jcrfsuite developer)</name>
            <url>http://github.com/juharris</url>
            <roles>
                <role>developer</role>
            </roles>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:git@github.com:gengoai/jcrfsuite.git</connection>
        <developerConnection>scm:git:git@github.com:gengoai/jcrfsuite.git</developerConnection>
        <url>git@github.com:gengoai/jcrfsuite.git</url>
    </scm>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <java.version>11</java.version>
    </properties>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.6</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>3.2.0</version>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.1.1</version>
                        <configuration>
                            <failOnError>false</failOnError>
                            <javadocExecutable>${java.home}/bin/javadoc</javadocExecutable>
                        </configuration>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <build>
        <resources>
            <resource>
                <directory>src/main/java</directory>
                <includes>
                    <include>third_party/org/chokkan/crfsuite/VERSION</include>
                </includes>
            </resource>
            <resource>
                <directory>src/main/resources</directory>
                <includes>
                    <include>crfsuite-0.12/**</include>
                </includes>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.1</version>
                <configuration>
                    <release>${java.version}</release>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>3.0.0-M1</version>
                <configuration>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                    <useReleaseProfile>false</useReleaseProfile>
                    <releaseProfiles>release</releaseProfiles>
                    <goals>deploy</goals>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.6.8</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>ossrh</serverId>
                    <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>true</autoReleaseAfterClose>
                </configuration>
            </plugin>
        </plugins>
    </build>
    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.11</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest-library</artifactId>
            <version>1.3</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
        </repository>
    </distributionManagement>
</project>
