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

	<name>jCIFS NG</name>
	<artifactId>jcifs-ng</artifactId>
	<groupId>eu.agno3.jcifs</groupId>
	<packaging>bundle</packaging>
	<version>2.0.8</version>

	<description>A pure-java CIFS/SMB client library</description>
	<url>https://github.com/AgNO3/jcifs-ng/</url>


	<licenses>
		<license>
			<name>LGPL</name>
			<url>https://www.gnu.org/licenses/lgpl.txt</url>
		</license>
	</licenses>

	<developers>
		<developer>
			<name>Moritz Bechler</name>
			<email>bechler@agno3.eu</email>
			<organization>AgNO3 GmbH &amp; Co. KG</organization>
			<organizationUrl>https://github.com/AgNO3/</organizationUrl>
		</developer>
	</developers>

	<scm>
		<connection>scm:git:https://github.com/AgNO3/jcifs-ng.git</connection>
		<developerConnection>scm:git:https://github.com/AgNO3/jcifs-ng.git</developerConnection>
		<url>git@github.com:AgNO3/jcifs-ng.git</url>
		<tag>jcifs-ng-2.0.8</tag>
	</scm>

	<distributionManagement>
		<snapshotRepository>
			<id>ossrh</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots</url>
		</snapshotRepository>
	</distributionManagement>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<java.sourceVersion>1.7</java.sourceVersion>
		<java.targetVersion>1.7</java.targetVersion>
		<maven.build.timestamp.format>yyyyMMddHHmm</maven.build.timestamp.format>
		<osgi-version-qualifier>${maven.build.timestamp}</osgi-version-qualifier>
		<project.scm.id>github</project.scm.id>
		<osgi.version>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}.${osgi-version-qualifier}</osgi.version>
		<osgi.pkg.version>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}</osgi.pkg.version>
	</properties>

	<dependencies>
		<dependency>
			<groupId>javax.servlet</groupId>
			<artifactId>javax.servlet-api</artifactId>
			<version>3.1.0</version>
			<scope>provided</scope>
		</dependency>
		 
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<version>1.7.24</version>
		</dependency>
		
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-log4j12</artifactId>
			<version>1.7.24</version>
			<scope>test</scope>
		</dependency>
		 
		<dependency>
			<groupId>org.bouncycastle</groupId>
			<artifactId>bcprov-jdk15on</artifactId>
			<version>1.54</version>
		</dependency>

		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.12</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.mockito</groupId>
			<artifactId>mockito-core</artifactId>
			<version>1.9.5</version>
			<scope>test</scope>
		</dependency>

	</dependencies>
	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.felix</groupId>
				<artifactId>maven-bundle-plugin</artifactId>
				<extensions>true</extensions>

				<configuration>
					<instructions>
						<Bundle-Version>${osgi.version}</Bundle-Version>
						<Bundle-License>LGPL</Bundle-License>
						<Bundle-Vendor>AgNO3 GmbH &amp; Co. KG</Bundle-Vendor>
						<Bundle-SymbolicName>eu.agno3.jcifsng</Bundle-SymbolicName>
						<Export-Package>
							jcifs.internal*;version="${osgi.pkg.version}";x-internal:=true,
							jcifs*;version="${osgi.pkg.version}",
						</Export-Package>
						<Private-Package />
						<Import-Package>
							javax.servlet*;resolution:=optional,
							com.sun.security.jgss;resolution:=optional,
							org.bouncycastle*;version="1.54",
							!jcifs.internal*,
							*
						</Import-Package>
					</instructions>
					<addDependenciesToRepository>true</addDependenciesToRepository>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<source>1.7</source>
					<target>1.7</target>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<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>
				<executions>
					<execution>
						<id>attach-javadocs</id>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<show>public</show>
					<excludePackageNames>jcifs.dcerpc.*:</excludePackageNames>
					<additionalparam>-Xdoclint:-missing</additionalparam>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>clirr-maven-plugin</artifactId>
				<executions> 
					<execution>
						<id>check-compatibility</id>
						<goals>
							<goal>check</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<ignored>
						<difference>
							<!-- seems to be a clirr bug that it cannot handle the different inherited 
								return types -->
							<className>**</className>
							<differenceType>7006</differenceType>
							<method>*</method>
							<from>*</from>
							<to>*</to>
						</difference>
						<difference>
							<!-- these were missing in 2.0.0 -->
							<className>jcifs/SmbRandomAccess</className>
							<differenceType>7012</differenceType>
							<method>*</method>
							<from>*</from>
							<to>*</to>
						</difference>
						<difference>
							<!-- added 2.0.1 -->
							<className>jcifs/SmbResource</className>
							<differenceType>7012</differenceType>
							<method>void renameTo(jcifs.SmbResource, boolean)</method>
							<from>*</from>
							<to>*</to>
						</difference>
						
						<difference>
							<!-- added 2.0.2 - needed for #14 fix -->
							<className>jcifs/internal/CommonServerMessageBlock</className>
							<differenceType>7012</differenceType>
							<method>long getMid()</method>
							<from>*</from>
							<to>*</to>
						</difference>
						
						<difference>
							<!-- added 2.0.2 - needed for #14 test -->
							<className>jcifs/smb/SmbTransportInternal</className>
							<differenceType>7012</differenceType>
							<method>int getInflightRequests()</method>
							<from>*</from>
							<to>*</to>
						</difference>
						
						<difference>
							<!-- added 2.0.2 - needed for #14 fix  -->
							<className>jcifs/util/transport/Response</className>
							<differenceType>7012</differenceType>
							<method>long getMid()</method>
							<from>*</from>
							<to>*</to>
						</difference>
						
						<difference>
							<!-- added 2.0.2 - needed for #14 fix  -->
							<className>jcifs/util/transport/Response</className>
							<differenceType>7012</differenceType>
							<method>void setMid(long)</method>
							<from>*</from>
							<to>*</to>
						</difference>

						<difference>
							<!-- added 2.0.6 - needed for #63 fix -->
							<className>jcifs/internal/TreeConnectResponse</className>
							<differenceType>7012</differenceType>
							<method>boolean isValidTid()</method>
							<from>*</from>
							<to>*</to>
						</difference>
					</ignored>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<configuration>
					<includes>
						<include>**/**Test.java</include>
					</includes>
					<systemPropertyVariables>
						<networkaddress.cache.ttl>-1</networkaddress.cache.ttl>
						<networkaddress.cache.negative.ttl>-1</networkaddress.cache.negative.ttl>
					</systemPropertyVariables>
					<properties>
						<property>
							<name>listener</name>
							<value>jcifs.tests.PrintingRunListener</value>
						</property>
					</properties>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.rat</groupId>
				<artifactId>apache-rat-plugin</artifactId>
				<executions>
					<execution>
						<phase>verify</phase>
						<goals>
							<goal>check</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<addDefaultLicenseMatchers>true</addDefaultLicenseMatchers>
					<excludes>
						<exclude>pom.xml</exclude>
						<exclude>breaking-changes.xml</exclude>
						<exclude>README.md</exclude>
						<exclude>build.properties</exclude>
						<exclude>src/test/resources/**</exclude>
						<exclude>**/*.idl</exclude>
						<exclude>**/*.css</exclude>
						<exclude>.*</exclude>
						<exclude>.*/**</exclude>
						<exclude>META-INF/**</exclude>
						<exclude>src/main/java/jcifs/dcerpc/msrpc/netdfs.java</exclude>
						<exclude>src/main/java/jcifs/dcerpc/msrpc/srvsvc.java</exclude>
						<exclude>src/main/java/jcifs/dcerpc/msrpc/samr.java</exclude>
						<exclude>src/main/java/jcifs/dcerpc/msrpc/lsarpc.java</exclude>
						<exclude>src/main/java/jcifs/dcerpc/rpc.java</exclude>
					</excludes>
					<licenses>
						<license implementation="org.apache.rat.analysis.license.SimplePatternBasedLicense">
							<licenseFamilyCategory>LGPL</licenseFamilyCategory>
							<licenseFamilyName>GNU Lesser General Public License</licenseFamilyName>
							<notes />
							<patterns>
								<pattern>This library is free software; you can redistribute it</pattern>
								<pattern>GNU Lesser General Public License</pattern>
							</patterns>
						</license>
					</licenses>
					<licenseFamilies>
						<licenseFamily implementation="org.apache.rat.license.SimpleLicenseFamily">
							<familyName>GNU Lesser General Public License</familyName>
						</licenseFamily>
					</licenseFamilies>
				</configuration>
			</plugin>
			<plugin>
				<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>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
				<configuration>
					<autoVersionSubmodules>true</autoVersionSubmodules>
					<useReleaseProfile>false</useReleaseProfile>
					<releaseProfiles>release</releaseProfiles>
					<goals>deploy</goals>
				</configuration>
			</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>

			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>build-helper-maven-plugin</artifactId>
				<version>1.8</version>
				<executions>
					<execution>
						<id>parse-version</id>
						<goals>
							<goal>parse-version</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>animal-sniffer-maven-plugin</artifactId>
				<executions>
					<execution>
						<phase>verify</phase>
						<goals>
							<goal>check</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<signature>
						<groupId>org.codehaus.mojo.signature</groupId>
						<artifactId>java17</artifactId>
						<version>1.0</version>
					</signature>	
				</configuration>
			</plugin>
		</plugins>
		<pluginManagement>
			<plugins>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-jarsigner-plugin</artifactId>
					<version>1.4</version>
				</plugin>
				<plugin>
					<groupId>org.codehaus.mojo</groupId>
					<artifactId>clirr-maven-plugin</artifactId>
					<version>2.8</version>
				</plugin>
				<plugin>
					<groupId>org.apache.rat</groupId>
					<artifactId>apache-rat-plugin</artifactId>
					<version>0.12</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-compiler-plugin</artifactId>
					<version>3.3</version>
				</plugin>
				<plugin>
					<groupId>org.apache.felix</groupId>
					<artifactId>maven-bundle-plugin</artifactId>
					<version>3.0.1</version>
				</plugin>
				<plugin>
					<groupId>org.sonatype.plugins</groupId>
					<artifactId>nexus-staging-maven-plugin</artifactId>
					<version>1.6.7</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-gpg-plugin</artifactId>
					<version>1.5</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-release-plugin</artifactId>
					<version>2.5.3</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-surefire-plugin</artifactId>
					<version>2.19.1</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-javadoc-plugin</artifactId>
					<version>2.10.4</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-source-plugin</artifactId>
					<version>3.0.1</version>
				</plugin>
				<plugin>
					<groupId>org.jacoco</groupId>
					<artifactId>jacoco-maven-plugin</artifactId>
					<version>0.7.9</version>
				</plugin>
				<plugin>
					<groupId>org.codehaus.mojo</groupId>
					<artifactId>animal-sniffer-maven-plugin</artifactId>
					<version>1.15</version>
				</plugin>
			</plugins>
		</pluginManagement>
	</build>

	<profiles>
		<profile>
			<id>release</id>
		</profile>
		<profile>
			<id>eclipse</id>
			<properties>
				<!-- within eclipse parsedVersion is not properly expanded, so just set this to a unqualified version -->
				<osgi.version>2.0.0</osgi.version>
				<osgi.pkg.version>2.0.0</osgi.pkg.version>
			</properties>
		</profile>
		<profile>
			<id>sign</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-jarsigner-plugin</artifactId>
						<executions>
							<execution>
								<id>sign</id>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
							<execution>
								<id>verify</id>
								<goals>
									<goal>verify</goal>
								</goals>
							</execution>
						</executions>
						<configuration>
							<arguments combine.children="append">
								<argument>-J-Djava.security.egd=file:/dev/./urandom</argument>
							</arguments>
							<alias>${sign.alias}</alias>
							<errorWhenNotSigned>true</errorWhenNotSigned>
							<tsa>${sign.tsa}</tsa>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>check-original-jcifs</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.codehaus.mojo</groupId>
						<artifactId>clirr-maven-plugin</artifactId>
						<executions>
							<execution>
								<id>check-original-compatibility</id>
								<goals>
									<goal>check</goal>
								</goals>
							</execution>
						</executions>
						<dependencies>
							<dependency>
								<groupId>javax.servlet</groupId>
								<artifactId>javax.servlet-api</artifactId>
								<version>3.1.0</version>
							</dependency>
						</dependencies>
						<configuration>
							<comparisonArtifacts>
								<comparisonArtifact>
									<groupId>jcifs</groupId>
									<artifactId>jcifs</artifactId>
									<version>1.3.18</version>
								</comparisonArtifact>
							</comparisonArtifacts>
							<excludes>
								<exclude>jcifs/http/**</exclude>
								<exclude>jcifs/https/**</exclude>
							</excludes>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>coverage</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.jacoco</groupId>
						<artifactId>jacoco-maven-plugin</artifactId>
						<executions>
							<execution>
								<id>default-prepare-agent</id>
								<goals><goal>prepare-agent</goal></goals>
							</execution>
							<execution>
								<id>default-report</id>
								<phase>prepare-package</phase>
								<goals><goal>report</goal></goals>
							</execution>
							<execution>
								<id>default-check</id>
								<goals><goal>check</goal></goals>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>
</project>
