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

    <groupId>org.w3c</groupId>
    <artifactId>epubcheck</artifactId>
    <version>5.3.0</version>

    <packaging>jar</packaging>

    <name>EPUBCheck :: the EPUB conformance checker</name>
    <description>EPUBCheck is the official conformance checker for EPUB publications. EPUBCheck can be run as a standalone command-line tool or used
      as a Java library.</description>
    <url>https://github.com/w3c/epubcheck</url>
    <inceptionYear>2007</inceptionYear>
    <organization>
        <name>The World Wide Web Consortium (W3C)</name>
        <url>https://www.w3.org</url>
    </organization>
    <licenses>
        <license>
            <name>BSD 3-Clause License</name>
            <url>http://www.opensource.org/licenses/bsd-license.php</url>
        </license>
    </licenses>
    <developers>
        <developer>
            <name>DAISY Consortium</name>
            <id>daisy</id>
            <email>contact-us@daisy.org</email>
            <url>https://daisy.org</url>
            <organization>DAISY Consortium</organization>
        </developer>
    </developers>
    <mailingLists>
        <mailingList>
            <name>EPUBCheck discussion</name>
            <subscribe>mailto:public-epubcheck-request@w3.org?subject=subscribe</subscribe>
            <unsubscribe>mailto:public-epubcheck-request@w3.org?subject=unsubscribe</unsubscribe>
            <post>public-epubcheck@w3.org</post>
            <archive>https://lists.w3.org/Archives/Public/public-epubcheck/</archive>
        </mailingList>
        <mailingList>
            <name>ARCHIVE: epubcheck discussion</name>
            <archive>https://groups.google.com/forum/#!forum/epubcheck</archive>
        </mailingList>
    </mailingLists>
    <scm>
        <connection>scm:git:ssh://git@github.com:w3c/epubcheck.git</connection>
        <developerConnection>scm:git:ssh://git@github.com:w3c/epubcheckgit</developerConnection>
        <url>https://github.com/w3c/epubcheck</url>
        <tag>v5.3.0</tag>
    </scm>
    <issueManagement>
        <system>Github</system>
        <url>https://github.com/w3c/epubcheck/issues</url>
    </issueManagement>

    <properties>
        <java.version>1.8</java.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <maven.build.timestamp.format>yyyy-MM-dd</maven.build.timestamp.format>
        <tool.build.date>${maven.build.timestamp}</tool.build.date>
    </properties>

    <dependencies>
        <dependency>
            <groupId>com.ibm.icu</groupId>
            <artifactId>icu4j</artifactId>
            <version>77.1</version>
        </dependency>
        <dependency>
            <groupId>net.sf.saxon</groupId>
            <artifactId>Saxon-HE</artifactId>
            <version>11.4</version>
        </dependency>
        <dependency>
            <groupId>nu.validator</groupId>
            <artifactId>galimatias</artifactId>
            <version>0.1.3</version>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-compress</artifactId>
            <version>1.28.0</version>
            <exclusions>
                <exclusion>
                    <groupId>org.tukaani</groupId>
                    <artifactId>xz</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.relaxng</groupId>
            <artifactId>jing</artifactId>
            <version>20181222</version>
            <exclusions>
                <exclusion>
                    <groupId>xml-apis</groupId>
                    <artifactId>xml-apis</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.w3c.css</groupId>
            <artifactId>sac</artifactId>
            <version>1.3</version>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>33.4.8-jre</version>
        </dependency>
        <dependency>
            <groupId>com.twelvemonkeys.imageio</groupId>
            <artifactId>imageio-jpeg</artifactId>
            <version>3.9.4</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-core</artifactId>
            <version>2.18.2</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
            <version>2.18.2</version>
        </dependency>
        <dependency>
            <groupId>xerces</groupId>
            <artifactId>xercesImpl</artifactId>
            <version>2.12.2</version>
        </dependency>
        <!-- ================= -->
        <!-- Test Dependencies -->
        <!-- ================= -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.13.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.googlecode.json-simple</groupId>
            <artifactId>json-simple</artifactId>
            <version>1.1.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.jayway.jsonpath</groupId>
            <artifactId>json-path-assert</artifactId>
            <version>2.8.0</version>
        </dependency>
        <dependency>
    	        <groupId>io.cucumber</groupId>
    	        <artifactId>cucumber-java</artifactId>
    	        <version>7.8.0</version>
    	        <scope>test</scope>
        </dependency>
        <dependency>
    	        <groupId>io.cucumber</groupId>
    	        <artifactId>cucumber-junit</artifactId>
    	        <version>7.8.0</version>
    	        <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>io.cucumber</groupId>
            <artifactId>cucumber-picocontainer</artifactId>
            <version>7.8.0</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest</artifactId>
            <version>2.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-nop</artifactId>
            <version>1.7.36</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <filtering>false</filtering>
                <directory>src/tools</directory>
                <targetPath>${project.build.directory}</targetPath>
            </resource>
            <resource>
                <directory>src/main/resources</directory>
                <excludes>
                    <exclude>com/adobe/epubcheck/schema/30/*.sch</exclude>
                    <exclude>com/thaiopensource/relaxng/pattern/resources/Messages.properties</exclude>
                    <exclude>com/thaiopensource/datatype/xsd/resources/Messages.properties</exclude>
                </excludes>
            </resource>
            <resource>
                <directory>src/main/resources</directory>
                <includes>
                    <include>com/adobe/epubcheck/api/project.properties</include>
                </includes>
                <filtering>true</filtering>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-enforcer-plugin</artifactId>
                <version>3.0.0-M3</version>
                <executions>
                <execution>
                    <id>enforce-maven</id>
                    <goals>
                        <goal>enforce</goal>
                    </goals>
                    <configuration>
                        <rules>
                            <requireMavenVersion>
                                <version>3.0</version>
                            </requireMavenVersion>
                        </rules>
                    </configuration>
                </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>3.0.2</version>
                <executions>
                    <execution>
                        <id>copy</id>
                        <phase>package</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>
                        <configuration>
                            <outputDirectory>${project.build.directory}/lib</outputDirectory>
                            <overWriteReleases>false</overWriteReleases>
                            <overWriteSnapshots>true</overWriteSnapshots>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.7.0</version>
                <configuration>
                    <source>${java.version}</source>
                    <target>${java.version}</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <version>5.1.8</version>
                <extensions>true</extensions>
                <executions>
                    <execution>
                        <id>bundle-manifest</id>
                        <phase>process-classes</phase>
                        <goals>
                            <goal>manifest</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <instructions>
                        <Import-Package>
                            net.sf.saxon.*;version="[11.4.0,11.4.1)",
                            *
                        </Import-Package>
                        <Automatic-Module-Name>org.w3c.epubcheck</Automatic-Module-Name>
                        <_removeheaders>Include-Resource,Private-Package, Bnd-LastModified, Build-Jdk, Built-By</_removeheaders>
                    </instructions>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.18.1</version>
                <configuration>
                    <argLine>-Xmx1g</argLine>
                    <workingDirectory>${project.build.directory}/test-classes</workingDirectory>
                    <!-- manifestFile>${project.build.directory}/classes/META-INF/MANIFEST.MF</manifestFile -->
                </configuration>
                <executions>
                    <execution>
                        <id>default-test</id>
                        <phase>test</phase>
                        <goals>
                            <goal>test</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-failsafe-plugin</artifactId>
              <version>2.22.1</version>
              <executions>
                <execution>
                  <goals>
                    <goal>integration-test</goal>
                    <goal>verify</goal>
                  </goals>
                </execution>
              </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>xml-maven-plugin</artifactId>
                <version>1.0.1</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>transform</goal>
                        </goals>
                        <phase>process-resources</phase>
                    </execution>
                </executions>
                <configuration>
                    <transformationSets>
                        <transformationSet>
                            <dir>src/main/resources/com/adobe/epubcheck/schema/30</dir>
                            <includes>
                                <include>*-30.sch</include>
                            </includes>
                            <stylesheet>src/main/util/sch/iso-sch-include.xsl</stylesheet>
                            <outputDir>${project.build.directory}/generated-resources/intermediate-schema</outputDir>
                        </transformationSet>
                        <transformationSet>
                            <dir>${project.build.directory}/generated-resources/intermediate-schema</dir>
                            <includes>
                                <include>*-30.sch</include>
                            </includes>
                            <stylesheet>src/main/util/sch/iso-sch-abstract.xsl</stylesheet>
                            <outputDir>${project.build.outputDirectory}/com/adobe/epubcheck/schema/30</outputDir>
                        </transformationSet>
                    </transformationSets>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>net.sf.saxon</groupId>
                        <artifactId>Saxon-HE</artifactId>
                        <version>11.4</version>
                    </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>license-maven-plugin</artifactId>
                <version>1.20</version>
                <executions>
                    <execution>
                        <id>thirdparty-licenses</id>
                        <goals>
                            <goal>add-third-party</goal>
                        </goals>
                        <configuration>
                            <includedScopes>runtime,compile</includedScopes>
                            <fileTemplate>${project.basedir}/src/main/licenses/THIRD-PARTY.ftl</fileTemplate>
                            <missingFile>${project.basedir}/src/main/licenses/THIRD-PARTY.properties</missingFile>
                            <deployMissingFile>false</deployMissingFile>
                            <useMissingFile>true</useMissingFile>
                            <includedScopes>runtime,compile</includedScopes>
                            <licenseMerges>
                                <licenseMerge>Apache License, Version 2.0|The Apache Software License, Version 2.0|Apache 2.0</licenseMerge>
                                <licenseMerge>The 3-Clause BSD License|The BSD License|3-clause BSD license</licenseMerge>
                                <licenseMerge>The MIT License|MIT license</licenseMerge>
                            </licenseMerges>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>3.0.2</version>
                <configuration>
                    <finalName>${project.artifactId}</finalName>
                    <archive>
                        <!--TODO Using the Manifest.MF file instead of the tag below is a work around for including two
         libraries that are not in the Nexus.  Currently they are checked into the lib directory.-->
                        <manifest>
                            <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
                            <mainClass>com.adobe.epubcheck.tool.Checker</mainClass>
                            <addClasspath>true</addClasspath>
                            <classpathPrefix>lib/</classpathPrefix>
                        </manifest>
                        <manifestFile>${project.build.directory}/classes/META-INF/MANIFEST.MF</manifestFile>
                        <manifestEntries>
                            <project-url>${project.url}</project-url>
                            <scm-location>${project.scm.developerConnection}</scm-location>
                        </manifestEntries>
                    </archive>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.11.3</version>
                <configuration>
                  <additionalparam>-Xdoclint:none</additionalparam>
                  <failOnError>false</failOnError>
                  <source>${java.version}</source>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.3.1</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-gpg-plugin</artifactId>
                <version>3.2.8</version>
            </plugin>
            <plugin>
                <!-- required to work around issues with git 1.8.5 and release-plugin -->
                <!-- https://jira.codehaus.org/browse/SCM-738 -->
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.5.3</version>
                <dependencies>
                    <dependency>
                        <groupId>org.apache.maven.scm</groupId>
                        <artifactId>maven-scm-provider-gitexe</artifactId>
                        <version>1.8.1</version>
                    </dependency>
                </dependencies>
                <configuration>
                    <tagNameFormat>v@{project.version}</tagNameFormat>
                    <scmCommentPrefix xml:space="preserve">chore: </scmCommentPrefix>
                    <mavenExecutorId>forked-path</mavenExecutorId>
                    <useReleaseProfile>false</useReleaseProfile>
                    <arguments>-Prelease</arguments>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>3.1.0</version>
                <executions>
                    <execution>
                        <id>dist-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <configuration>
                            <attach>false</attach>
                            <appendAssemblyId>false</appendAssemblyId>
                            <descriptors>
                                <descriptor>src/main/assembly/dist.xml</descriptor>
                            </descriptors>
                        </configuration>
                    </execution>
                    <execution>
                        <id>src-assembly</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                        <configuration>
                            <attach>false</attach>
                            <descriptors>
                                <descriptor>src/main/assembly/src.xml</descriptor>
                            </descriptors>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.sonatype.central</groupId>
                <artifactId>central-publishing-maven-plugin</artifactId>
                <version>0.8.0</version>
                <extensions>true</extensions>
                <configuration>
                    <publishingServerId>central</publishingServerId>
                </configuration>
            </plugin>
        </plugins>
        <pluginManagement>
            <plugins>
                <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
                <plugin>
                    <groupId>org.eclipse.m2e</groupId>
                    <artifactId>lifecycle-mapping</artifactId>
                    <version>1.0.0</version>
                    <configuration>
                        <lifecycleMappingMetadata>
                            <pluginExecutions>
                                <pluginExecution>
                                    <pluginExecutionFilter>
                                        <groupId>org.codehaus.mojo</groupId>
                                        <artifactId>xml-maven-plugin</artifactId>
                                        <versionRange>[1.0,)</versionRange>
                                        <goals>
                                            <goal>transform</goal>
                                        </goals>
                                    </pluginExecutionFilter>
                                    <action>
                                        <execute />
                                    </action>
                                </pluginExecution>
                                <pluginExecution>
                                    <pluginExecutionFilter>
                                        <groupId>org.codehaus.mojo</groupId>
                                        <artifactId>license-maven-plugin</artifactId>
                                        <versionRange>[1.0,)</versionRange>
                                        <goals>
                                            <goal>add-third-party</goal>
                                        </goals>
                                    </pluginExecutionFilter>
                                    <action>
                                        <ignore />
                                    </action>
                                </pluginExecution>
                                <pluginExecution>
                                    <pluginExecutionFilter>
                                        <groupId> org.apache.felix </groupId>
                                        <artifactId> maven-bundle-plugin </artifactId>
                                        <versionRange> [2.3.7,) </versionRange>
                                        <goals>
                                            <goal>manifest</goal>
                                        </goals>
                                    </pluginExecutionFilter>
                                    <action>
                                        <execute />
                                    </action>
                                </pluginExecution>
                            </pluginExecutions>
                        </lifecycleMappingMetadata>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>
    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
