<?xml version='1.0' encoding='UTF-8'?>
<project
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://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>

	<groupId>org.eclipse.californium</groupId>
	<artifactId>parent</artifactId>
	<version>2.0.0-M14</version>
	<packaging>pom</packaging>

	<name>Californium (Cf) Parent</name>
	<description>Common definitions and configuration for all Californium (Cf) components</description>
	<url>https://www.eclipse.org/californium/</url>
	<organization>
		<name>Eclipse Foundation</name>
		<url>http://www.eclipse.org/</url>
	</organization>
	<licenses>
		<license>
			<name>Eclipse Public License - Version 1.0</name>
			<url>http://www.eclipse.org/org/documents/epl-v10.php</url>
		</license>
		<license>
			<name>Eclipse Distribution License - Version 1.0</name>
			<url>http://www.eclipse.org/org/documents/edl-v10.php</url>
		</license>
	</licenses>
	<scm>
		<developerConnection>scm:git:ssh://git@github.com/eclipse/californium.git</developerConnection>
		<url>https://github.com/eclipse/californium</url>
		<tag>HEAD</tag>
	</scm>
	<issueManagement>
		<system>Bugzilla</system>
		<url>https://bugs.eclipse.org/bugs/buglist.cgi?product=Californium</url>
	</issueManagement>
	<ciManagement>
		<system>Jenkins</system>
		<url>https://ci.eclipse.org/californium/</url>
	</ciManagement>
	<developers>
		<developer>
			<id>mkovatsch</id>
			<name>Matthias Kovatsch</name>
			<email>kovatsch@inf.ethz.ch</email>
			<url>http://people.inf.ethz.ch/mkovatsc/</url>
			<organization>ETH Zurich</organization>
			<organizationUrl>http://www.vs.inf.ethz.ch/</organizationUrl>
			<roles>
				<role>Committer</role>
				<role>Lead</role>
			</roles>
		</developer>
		<developer>
			<id>mlanter</id>
			<name>Martin Lanter</name>
			<email>martin.lanter@gmx.ch</email>
			<roles>
				<role>Committer</role>
			</roles>
		</developer>
		<developer>
			<id>jvermillard</id>
			<name>Julien Vermillard</name>
			<email>jvermillar@sierrawireless.com</email>
			<organization>Sierra Wireless</organization>
			<roles>
				<role>Committer</role>
			</roles>
		</developer>
		<developer>
			<id>khudalla</id>
			<name>Kai Hudalla</name>
			<email>kai.hudalla@bosch-si.com</email>
			<url>https://github.com/sophokles73</url>
			<organization>Bosch Software Innovations GmbH</organization>
			<organizationUrl>http://www.bosch-si.com</organizationUrl>
			<roles>
				<role>Committer</role>
			</roles>
		</developer>
		<developer>
			<id>sbernard</id>
			<name>Simon Bernard</name>
			<email>sbernard@sierrawireless.com</email>
			<organization>Sierra Wireless</organization>
			<roles>
				<role>Committer</role>
			</roles>
		</developer>
		<developer>
			<id>boaks</id>
			<name>Achim Kraus</name>
			<email>achim.kraus@bosch-si.com</email>
			<organization>Bosch Software Innovations GmbH</organization>
			<organizationUrl>http://www.bosch-si.com</organizationUrl>
			<roles>
				<role>Committer</role>
			</roles>
		</developer>
	</developers>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.build.javaVersion>1.7</project.build.javaVersion>
		<snapshotDependencyAllowed>true</snapshotDependencyAllowed>
		<hamcrest.version>1.3</hamcrest.version>
		<junit.version>4.12</junit.version>
		<logback.version>1.2.3</logback.version>
		<mockito.version>1.10.19</mockito.version>
		<slf4j.version>1.7.25</slf4j.version>
	</properties>

	<distributionManagement>
		<repository>
			<id>repo.eclipse.org</id>
			<name>Californium Repository - Releases</name>
			<url>https://repo.eclipse.org/content/repositories/californium-releases/</url>
		</repository>
		<snapshotRepository>
			<id>repo.eclipse.org</id>
			<name>Californium Repository - Snapshots</name>
			<url>https://repo.eclipse.org/content/repositories/californium-snapshots/</url>
		</snapshotRepository>
	</distributionManagement>

	<repositories>
		<repository>
			<id>eclipse_snapshots</id>
			<name>Eclipse Snapshots</name>
			<url>https://repo.eclipse.org/content/repositories/snapshots/</url>
		</repository>
	</repositories>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>californium-legal</artifactId>
				<version>${project.version}</version>
				<scope>runtime</scope>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>element-connector</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>element-connector-tcp</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>scandium</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>californium-core</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>californium-proxy</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>cf-nat</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>org.slf4j</groupId>
				<artifactId>slf4j-api</artifactId>
				<version>${slf4j.version}</version>
			</dependency>
			
			<!--  tests & runtime -->
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>demo-certs</artifactId>
				<version>${project.version}</version>
			</dependency>
			
			<dependency>
				<groupId>ch.qos.logback</groupId>
				<artifactId>logback-classic</artifactId>
				<version>${logback.version}</version>
			</dependency>
			
			<!--  tests -->
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>element-connector</artifactId>
				<version>${project.version}</version>
				<classifier>tests</classifier>
				<type>test-jar</type>
			</dependency>
			<dependency>
				<groupId>${project.groupId}</groupId>
				<artifactId>californium-core</artifactId>
				<version>${project.version}</version>
				<classifier>tests</classifier>
				<type>test-jar</type>
			</dependency>
			<dependency>
				<groupId>junit</groupId>
				<artifactId>junit</artifactId>
				<version>${junit.version}</version>
			</dependency>
			<dependency>
				<groupId>org.mockito</groupId>
				<artifactId>mockito-all</artifactId>
				<version>${mockito.version}</version>
			</dependency>
			<dependency>
				<groupId>org.hamcrest</groupId>
				<artifactId>hamcrest-library</artifactId>
				<version>${hamcrest.version}</version>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<modules>
		<module>element-connector</module>
		<module>scandium-core</module>
		<module>element-connector-tcp</module>
		<module>californium-core</module>
		<module>californium-integration-tests</module>
		<module>californium-proxy</module>
		<module>californium-osgi</module>
		<module>demo-apps</module>
		<module>demo-certs</module>
		<module>legal</module>
		<module>cf-oscore</module>
	</modules>

	<build>
		<pluginManagement>
			<plugins>
				<plugin>
					<artifactId>maven-clean-plugin</artifactId>
					<version>3.1.0</version>
				</plugin>
				<plugin>
					<artifactId>maven-deploy-plugin</artifactId>
					<version>2.8.2</version>
				</plugin>
				<plugin>
					<artifactId>maven-install-plugin</artifactId>
					<version>2.5.2</version>
				</plugin>
				<plugin>
					<artifactId>maven-resources-plugin</artifactId>
					<version>3.1.0</version>
				</plugin>
				<plugin>
					<artifactId>maven-site-plugin</artifactId>
					<version>3.7.1</version>
				</plugin>
				<plugin>
					<artifactId>maven-dependency-plugin</artifactId>
					<version>3.1.1</version>
				</plugin>
				<plugin>
					<artifactId>maven-compiler-plugin</artifactId>
					<version>3.8.0</version>
					<configuration>
						<source>${project.build.javaVersion}</source>
						<target>${project.build.javaVersion}</target>
						<encoding>${project.build.sourceEncoding}</encoding>
					</configuration>
				</plugin>
				<plugin>
					<artifactId>maven-source-plugin</artifactId>
					<version>3.0.1</version>
					<executions>
						<execution>
							<id>attach-sources</id>
							<phase>verify</phase>
							<goals>
								<goal>jar-no-fork</goal>
							</goals>
						</execution>
					</executions>
				</plugin>
				<plugin>
					<artifactId>maven-surefire-plugin</artifactId>
					<version>2.22.1</version>
					<configuration>
						<useSystemClassLoader>false</useSystemClassLoader>
						<systemPropertyVariables>
							<!--
								configures the logback logging framework to use a config file
							-->
							<logback.configurationFile>${project.basedir}/logback-test.xml</logback.configurationFile>
							<org.eclipse.californium.junit.socketmode>DIRECT</org.eclipse.californium.junit.socketmode>
						</systemPropertyVariables>
						<excludes>
							<exclude>**/*$*</exclude>
						</excludes>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.apache.felix</groupId>
					<artifactId>maven-bundle-plugin</artifactId>
					<version>3.5.0</version>
				</plugin>
				<plugin>
					<artifactId>maven-javadoc-plugin</artifactId>
					<version>3.0.1</version>
					<executions>
						<execution>
							<id>attach-javadocs</id>
							<goals>
								<goal>jar</goal>
							</goals>
						</execution>
					</executions>
					<configuration>
						<doclint>none</doclint>
						<additionalparam>${javadoc.opts}</additionalparam>
					</configuration>
				</plugin>
				<plugin>
					<artifactId>maven-assembly-plugin</artifactId>
					<version>3.1.1</version>
					<inherited>true</inherited>
					<configuration>
						<appendAssemblyId>false</appendAssemblyId>
						<attach>false</attach>
						<archive>
							<manifest>
								<mainClass>${assembly.mainClass}</mainClass>
								<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
							</manifest>
						</archive>
						<descriptors>
							<descriptor>enhanced-jar-with-dependencies.xml</descriptor>
						</descriptors>
					</configuration>
					<executions>
						<execution>
							<id>make-assembly</id>
							<phase>package</phase>
							<goals>
								<goal>single</goal>
							</goals>
						</execution>
					</executions>
				</plugin>
				<plugin>
					<artifactId>maven-jar-plugin</artifactId>
					<version>3.1.1</version>
				</plugin>
				<plugin>
					<artifactId>maven-enforcer-plugin</artifactId>
					<version>1.4.1</version>
				</plugin>
				<plugin>
					<groupId>org.sonatype.plugins</groupId>
					<artifactId>nexus-staging-maven-plugin</artifactId>
					<version>1.6.8</version>
				</plugin>
				<plugin>
					<artifactId>maven-gpg-plugin</artifactId>
					<version>1.6</version>
				</plugin>
				<plugin>
					<groupId>org.codehaus.mojo</groupId>
					<artifactId>animal-sniffer-maven-plugin</artifactId>
					<version>1.17</version>
					<configuration>
						<signature>
							<groupId>net.sf.androidscents.signature</groupId>
							<artifactId>android-api-level-16</artifactId>
							<version>4.1.2_r5</version>
						</signature>
						<annotations>
							<annotation>org.eclipse.californium.elements.util.NotForAndroid</annotation>
						</annotations>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.codehaus.mojo</groupId>
					<artifactId>license-maven-plugin</artifactId>
					<version>1.16</version>
				</plugin>
			</plugins>
		</pluginManagement>

		<plugins>
			<plugin>
				<artifactId>maven-enforcer-plugin</artifactId>
				<executions>
					<execution>
						<id>enforce-maven</id>
						<goals>
							<goal>enforce</goal>
						</goals>
						<configuration>
							<rules>
								<requireMavenVersion>
									<version>3.0.5</version>
								</requireMavenVersion>
							</rules>
						</configuration>
					</execution>
					<execution>
						<!-- Make sure that only non-snapshot versions are used for the dependencies. 
							Only active when property 'snapshotDependencyAllowed' is false. -->
						<id>enforce-no-snapshots</id>
						<goals>
							<goal>enforce</goal>
						</goals>
						<configuration>
							<skip>${snapshotDependencyAllowed}</skip>
							<rules>
								<requireReleaseDeps>
									<message>No Snapshots Allowed!</message>
								</requireReleaseDeps>
								<requireReleaseVersion>
									<message>No Snapshots Allowed!</message>
								</requireReleaseVersion>
							</rules>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<artifactId>maven-source-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>license-maven-plugin</artifactId>
			</plugin>
			<plugin>
				<!-- 
					Use the Nexus Staging plugin as a full replacement for the standard
					Maven Deploy plugin.
					See https://github.com/sonatype/nexus-maven-plugins/tree/master/staging/maven-plugin
					why this makes sense :-)
					We can control whether we want to deploy to the Eclipse repo or Maven Central
					by a combination of the version being a SNAPHOT or release version and property
					skipStaging=true/false.
					In any case we can take advantage of the plugin's "deferred deploy" feature which
					makes sure that all artifacts of a multi-module project are deployed as a whole
					at the end of the build process instead of deploying each module's artifacts
					individually as part of building the module.
				 -->
				<groupId>org.sonatype.plugins</groupId>
				<artifactId>nexus-staging-maven-plugin</artifactId>
				<extensions>true</extensions>
				<configuration>
					<serverId>ossrh</serverId>
					<nexusUrl>https://oss.sonatype.org/</nexusUrl>
					<autoReleaseAfterClose>false</autoReleaseAfterClose>
				</configuration>
			</plugin>
		</plugins>
	</build>

	<profiles>
		<profile>
			<!--
				this profile downloads licenses used by 3rd-party library
			-->
			<id>download-licenses</id>
			<activation>
				<activeByDefault>false</activeByDefault>
				<property>
					<name>downloadLicenses</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.codehaus.mojo</groupId>
						<artifactId>license-maven-plugin</artifactId>
						<executions>
							<execution>
								<id>download-licenses</id>
								<configuration>
									<excludedGroups>org.eclipse.californium</excludedGroups>
									<excludedScopes>system,test</excludedScopes>
								</configuration>
								<goals>
									<goal>download-licenses</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<!--
				this profile generates javadoc to check integrity
				sub-modules can set property maven.javadoc.skip=true in order to skip this
				(e.g., the executable examples, which do not require Javadoc)
			-->
			<id>javadoc</id>
			<activation>
				<activeByDefault>false</activeByDefault>
				<property>
					<name>createJavadoc</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<artifactId>maven-javadoc-plugin</artifactId>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>java11-html4</id>
			<activation>
				<jdk>[1.11,)</jdk>
			</activation>
			<properties>
				<javadoc.opts>-X-html4</javadoc.opts>
			</properties>
		</profile>
		<profile>
			<!-- this profile signs artifacts so that they can be deployed to repo.eclipse.org -->
			<id>eclipse_jar_signing</id>
			<activation>
				<activeByDefault>false</activeByDefault>
				<property>
					<name>enableEclipseJarSigner</name>
				</property>
			</activation>
			<pluginRepositories>
				<pluginRepository>
					<id>eclipse-repo</id>
					<name>Eclipse Repository</name>
					<releases>
						<enabled>true</enabled>
					</releases>
					<snapshots>
						<enabled>false</enabled>
					</snapshots>
					<url>https://repo.eclipse.org/content/repositories/releases/</url>
				</pluginRepository>
			</pluginRepositories>
			<build>
				<plugins>
					<plugin>
						<groupId>org.eclipse.cbi.maven.plugins</groupId>
						<artifactId>eclipse-jarsigner-plugin</artifactId>
						<version>1.1.3</version>
						<executions>
							<execution>
								<id>sign-jars</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<!-- this profile generates GPG signatures -->
			<id>create_gpg_signature</id>
			<activation>
				<activeByDefault>false</activeByDefault>
				<property>
					<name>createGPGSignature</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<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>
