<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>eu.europa.ec.joinup.sd-dss</groupId>
		<artifactId>sd-dss</artifactId>
		<version>6.0</version>
	</parent>

	<artifactId>dss-simple-report-jaxb</artifactId>
	<name>JAXB Simple Report Model</name>
	<description>Generated source from XSD for Simple Report and additional XSLT (for HTML/PDF renderings).</description>

	<properties>
		<module-name>jpms_dss_simple_report</module-name>
	</properties>
	
	<build>
		<!-- Inject version number in XSLT -->
		<resources>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>true</filtering>
				<includes>
					<include>**/*.xslt</include>
				</includes>
			</resource>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>false</filtering>
				<excludes>
					<exclude>**/*.xslt</exclude>
				</excludes>
			</resource>
		</resources>
		
		<plugins>
			<plugin>
				<groupId>org.jvnet.jaxb</groupId>
				<artifactId>jaxb-maven-plugin</artifactId>
				<executions>
					<execution>
						<phase>generate-sources</phase>
						<goals>
							<goal>generate</goal>
						</goals>
						<configuration>
							<schemaDirectory>src/main/resources/xsd</schemaDirectory>
							<generatePackage>eu.europa.esig.dss.simplereport.jaxb</generatePackage>
							<schemaIncludes>
								<schemaInclude>SimpleReport.xsd</schemaInclude>
							</schemaIncludes>
							<bindingIncludes>
								<include>bindings.xml</include>
							</bindingIncludes>
							<specVersion>3.0</specVersion>
							<encoding>UTF-8</encoding>
							<locale>en</locale>
						</configuration>
					</execution>
				</executions>
				<dependencies>
					<dependency>
						<groupId>org.glassfish.jaxb</groupId>
						<artifactId>jaxb-runtime</artifactId>
						<version>3.0.2</version>
					</dependency>
				</dependencies>
			</plugin>
			<plugin>
			    <groupId>org.codehaus.mojo</groupId>
			    <artifactId>build-helper-maven-plugin</artifactId>
			    <executions>
			        <execution>
			            <id>add-source</id>
			            <!-- after generate-sources / process-sources -->
			            <phase>compile</phase>
			            <goals>
			                <goal>add-source</goal>
			            </goals>
			            <configuration>
			                <sources>
			                    <source>${project.build.directory}/generated-sources/xjc/</source>
			                </sources>
			            </configuration>
			        </execution>
			    </executions>
			 </plugin>
		</plugins>
	</build>

	<dependencies>
		<dependency>
			<groupId>eu.europa.ec.joinup.sd-dss</groupId>
			<artifactId>dss-jaxb-parsers</artifactId>
		</dependency>
		
		<dependency>
		    <groupId>org.junit.platform</groupId>
		    <artifactId>junit-platform-launcher</artifactId>
		    <scope>test</scope>
		</dependency>
		<dependency>
		    <groupId>org.junit.jupiter</groupId>
		    <artifactId>junit-jupiter-engine</artifactId>
		    <scope>test</scope>
		</dependency>
		
		<dependency>
			<groupId>org.apache.xmlgraphics</groupId>
			<artifactId>fop-core</artifactId>
		    <scope>test</scope>
			<exclusions>
				<exclusion>
					<artifactId>commons-logging</artifactId>
					<groupId>commons-logging</groupId>
				</exclusion>
				<exclusion>
					<groupId>xalan</groupId>
					<artifactId>xalan</artifactId>
				</exclusion>
				<exclusion>
					<groupId>javax.servlet</groupId>
					<artifactId>servlet-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.apache.ant</groupId>
					<artifactId>ant</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		
		<!-- replace commons-logging -->
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>jcl-over-slf4j</artifactId>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>ch.qos.logback</groupId>
			<artifactId>logback-classic</artifactId>
			<scope>test</scope>
		</dependency>
		
	</dependencies>
	
	<profiles>
		<profile>
            <id>jdk19-plus</id>
            <activation>
                <jdk>[9,13)</jdk>
            </activation>
            <properties>
				<!-- specs-xmldsig\target\generated-sources\xjc\eu\europa\esig\xmldsig\jaxb\package-info.java:8: error: unknown tag: jakarta.xml.bind.annotation.XmlSchema -->
				<maven.javadoc.skip>true</maven.javadoc.skip>
            </properties>
		</profile>
	</profiles>
	
</project>
