<project>
	<modelVersion>4.0.0</modelVersion>

	<groupId>com.github.codemonstur</groupId>
	<artifactId>jpedal</artifactId>
	<version>4.92-p13</version>

    <name>${project.groupId}:${project.artifactId}</name>
    <description>Patched jPedal based on the last official jpedal version 4.92</description>
    <url>https://github.com/codemonstur/jpedal</url>

    <licenses>
        <license>
            <name>LGPL 2.1 License</name>
            <url>https://opensource.org/licenses/LGPL-2.1</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <connection>scm:git:https://github.com/codemonstur/jpedal.git</connection>
        <developerConnection>scm:git:https://github.com/codemonstur/jpedal.git</developerConnection>
        <url>https://github.com/codemonstur/jpedal</url>
        <tag>HEAD</tag>
    </scm>

    <developers>
        <developer>
            <id>codemonstur</id>
            <name>Jurgen Voorneveld</name>
            <email>jegvoorneveld@gmail.com</email>
        </developer>
    </developers>

    <properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <maven.compiler.source>1.8</maven.compiler.source>
        <maven.compiler.target>1.8</maven.compiler.target>
	</properties>

    <distributionManagement>
        <snapshotRepository>
            <id>sonatype-nexus-snapshots</id>
            <name>Sonatype Nexus snapshot repository</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>sonatype-nexus-staging</id>
            <name>Sonatype Nexus release repository</name>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>

    <profiles>
        <profile>
            <id>release</id>
            <activation>
                <property>
                    <name>release</name>
                    <value>true</value>
                </property>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.5</version>
                        <configuration>
                            <passphrase>${gpg.passphrase}</passphrase>
                        </configuration>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <build>
        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>3.2.0</version>
                <configuration>
                    <archive>
                        <manifest>
                            <addDefaultSpecificationEntries>false</addDefaultSpecificationEntries>
                            <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            <mainClass>org.jpedal.examples.viewer.Viewer</mainClass>
                            <!-- addClasspath=true causes warnings during wildfly deployment and is not necessary. See WFLYSRV0059 https://access.redhat.com/solutions/795493 -->
                            <addClasspath>false</addClasspath>
                        </manifest>
                    </archive>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.6.12</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>sonatype-nexus-staging</serverId>
                    <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>true</autoReleaseAfterClose>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.2.1</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals><goal>jar</goal></goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.3.0</version>
                <configuration>
                    <additionalOptions>
                        <additionalOption>-Xdoclint:none</additionalOption>
                    </additionalOptions>
                    <doclint>none</doclint>
                </configuration>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals><goal>jar</goal></goals>
                    </execution>
                </executions>
            </plugin>

		</plugins>
	</build>

	<dependencies>

        <dependency>
			<groupId>javax.media</groupId>
			<artifactId>jai_core</artifactId>
			<version>1.1.3</version>
		</dependency>

		<dependency>
			<groupId>javax.media</groupId>
			<artifactId>jai_codec</artifactId>
			<version>1.1.3</version>
		</dependency>

		<dependency>
            <groupId>com.github.jai-imageio</groupId>
            <artifactId>jai-imageio-core</artifactId>
            <version>1.4.0</version>
		</dependency>

		<!-- To restore jpg2K format for jpedal pdf-to-image conversion -->
		<dependency>
    		<groupId>com.github.jai-imageio</groupId>
    		<artifactId>jai-imageio-jpeg2000</artifactId>
    		<version>1.3.0</version>
		</dependency>

		<dependency>
            <groupId>org.bouncycastle</groupId>
            <artifactId>bcprov-jdk15on</artifactId>
            <version>1.56</version>
        </dependency>

		<dependency>
			<groupId>org.bouncycastle</groupId>
			<artifactId>bcmail-jdk15on</artifactId>
			<version>1.56</version>
		</dependency>
	</dependencies>
	
	<repositories>
		<repository>
            <id>central</id>
            <name>Central Repository</name>
            <url>https://repo.maven.apache.org/maven2</url>
            <layout>default</layout>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
		</repository>

		<repository>
			<id>Geotoolkit</id>
			<layout>default</layout>
			<name>geotoolkit-repo-3rd-party</name>
			<snapshots>
				<enabled>false</enabled>
			</snapshots>
			<url>https://nexus.geomatys.com/repository/geotoolkit</url>
		</repository>
    </repositories>

</project>
