<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>com.cyc</groupId>
  <artifactId>cyc-core-api</artifactId>
  <version>1.0.0-rc1</version>
  <packaging>pom</packaging>
  
  <name>Cyc Core API Suite</name>
  <description>The core Java APIs for interacting with the Cyc inference engine and knowledge base.</description>
  <url>http://dev.cyc.com/cyc-api/</url>
  
  <scm>
    <connection>scm:git:git@github.com:cycorp/CycCoreAPI.git</connection>
    <developerConnection>scm:git:git@github.com:cycorp/CycCoreAPI.git</developerConnection>
    <url>https://github.com/cycorp/CycCoreAPI</url>
  </scm>
  
  <issueManagement>
    <url>https://github.com/cycorp/CycCoreAPI/issues</url>
    <system>GitHub Issues</system>
  </issueManagement>
  
  <inceptionYear>2013</inceptionYear>
  
  <licenses>
    <license>
      <name>The Apache License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
    </license>
  </licenses>
  
  <organization>
    <name>Cycorp, Inc.</name>
    <url>http://www.cyc.com</url>
  </organization>
  
  <developers>
    <developer>
      <name>Cycorp API Team</name>
      <email>api-devs@cyc.com</email>
      <organization>Cycorp, Inc.</organization>
      <organizationUrl>http://www.cyc.com</organizationUrl>
    </developer>
  </developers>

  <distributionManagement>
    <snapshotRepository>
      <id>ossrh</id>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <repository>
      <id>ossrh</id>
      <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
  </distributionManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <svnRevisionNumberPluginVersion>1.13</svnRevisionNumberPluginVersion>
    <!-- maven.build.timestamp doesn't make it through to the filtering mechanism,
         so we need to store it in another property. Details: 
         http://java.dzone.com/tips/stamping-version-number-and
    -->
    <timestamp>${maven.build.timestamp}</timestamp>
    <maven.build.timestamp.format>yyyy-MM-dd HH:mm:ss</maven.build.timestamp.format>
    <project.root>${project.parent.basedir}</project.root>
  </properties>
    
  <modules>
    <module>SessionAPI</module>
    <module>BaseClient</module>
    <module>KBAPI</module>
    <module>QueryAPI</module>
  </modules>
  
  <profiles>
    <profile>
      <id>doclint-java8-disable</id>
      <activation>
        <jdk>[1.8,)</jdk>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <configuration>
              <additionalparam>-Xdoclint:none</additionalparam>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>release</id>
      <build>
	<plugins>
	  <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.5</version>
            <executions>
              <execution>
		<id>sign-artifacts</id>
		<phase>verify</phase>
		<goals>
		  <goal>sign</goal>
		</goals>
              </execution>
            </executions>
	  </plugin>
	  <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <version>2.3</version>
            <executions>
              <execution>
		<id>attach-sources</id>
		<goals>
		  <goal>jar-no-fork</goal>
		</goals>
              </execution>
  	      <!--
              <execution>
                <id>bundle-sources</id>
                <phase>package</phase>
                <goals>
                  <goal>jar-no-fork</goal>
                </goals>
              </execution>
              -->
            </executions>
	  </plugin>
	  <plugin>
	    <groupId>org.apache.maven.plugins</groupId>
	    <artifactId>maven-javadoc-plugin</artifactId>
	    <configuration>
              <detectOfflineLinks>false</detectOfflineLinks>
              <tags>
		<tag>
		  <name>date</name>
		  <!-- The value X makes javadoc ignore the tag -->
		  <placement>X</placement>
		</tag>
		<tag>
		  <name>note</name>
		  <placement>X</placement>
		</tag>
		<tag>
		  <name>owner</name>
		  <placement>X</placement>
		</tag>
		<tag>
		  <name>privacy</name>
		  <placement>X</placement>
		</tag>                        
		<tag>
		  <name>obsolete</name>
		  <placement>X</placement>
		</tag>
              </tags>
              <author>false</author>
              <version>false</version>
            </configuration>
	    <executions>
              <execution>
		<id>attach-javadocs</id>
		<goals>
		  <goal>jar</goal>
		</goals>
              </execution>
              <!--
	      <execution>
		<id>default-cli</id>
		<phase>site</phase>
		<goals>
		  <goal>aggregate</goal>
		</goals>
		<configuration>
		  <subpackages>
                    com.cyc:org.opencyc
		  </subpackages>
		  <!- - switch on dependency-driven aggregation - ->
		  <includeDependencySources>true</includeDependencySources>
		  <sourceFileExcludes>
                    <exclude>**/generated-sources/**/package-info.java</exclude>
		  </sourceFileExcludes>
		  <dependencySourceExcludes>
                    <dependencySourceExclude>com.google.code.findbugs:jsr305</dependencySourceExclude>
                    <dependencySourceExclude>commons-lang:commons-lang</dependencySourceExclude>
		  </dependencySourceExcludes>
		  <author>false</author>
		</configuration>
              </execution>
              <execution>
		<id>resource-bundles</id>
		<phase>package</phase>
		<goals>
		  <!- - produce source artifact for main project sources - ->
		  <goal>resource-bundle</goal>
		</goals>
		<configuration>
		  <detectOfflineLinks>false</detectOfflineLinks>
		</configuration>
              </execution>
	      -->
	    </executions>
	  </plugin>
	</plugins>
      </build>
    </profile>
  </profiles>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>license-maven-plugin</artifactId>
          <version>1.7</version>
          <configuration>
            <verbose>false</verbose>
            <addSvnKeyWords>false</addSvnKeyWords>
            <canUpdateDescription>true</canUpdateDescription>
            <descriptionTemplate>${project.root}/src/resources/headerTemplate.ftl</descriptionTemplate>
            <canUpdateCopyright>true</canUpdateCopyright>
          </configuration>
          <executions>
            <execution>
              <id>first</id>
              <goals>
                <goal>update-file-header</goal>
              </goals>
              <phase>process-sources</phase>
              <configuration>
                <licenseName>apache_v2</licenseName>
                <roots>
                  <root>src/main/java</root>
                  <root>src/test</root>
                </roots>
              </configuration>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.1</version>
          <configuration>
            <source>1.6</source>
            <target>1.6</target>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>
    
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.1</version>
        <configuration>
          <source>1.6</source>
          <target>1.6</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-site-plugin</artifactId>
        <version>3.3</version>
        <dependencies>
          <dependency>
            <groupId>org.apache.maven.wagon</groupId>
            <artifactId>wagon-ssh</artifactId>
            <version>2.0</version>
          </dependency>
        </dependencies>
      </plugin>
      <!--
      <plugin> 
        <groupId>org.apache.maven.plugins</groupId> 
        <artifactId>maven-assembly-plugin</artifactId> 
        <configuration> 
          <archive> 
            <manifest> 
              <addClasspath>true</addClasspath> 
              <addDefaultImplementationEntries>true</addDefaultImplementationEntries> 
              <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries> 
            </manifest> 
          </archive> 
          <descriptorRefs> 
            <descriptorRefs>jar-with-dependencies</descriptorRefs> 
          </descriptorRefs> 
          <!- -descriptors>
              <descriptor>src/main/assembly/all-jar.xml</descriptor>
          </descriptors- ->
        </configuration> 
        <executions>
          <execution>
            <id>package-all</id>
            <phase>package</phase>
            <goals>
              <goal>single</goal>
            </goals>                        
          </execution>
        </executions>
      </plugin> 
      <plugin> 
        <groupId>org.apache.maven.plugins</groupId> 
        <artifactId>maven-jar-plugin</artifactId> 
        <version>2.1</version> 
        <configuration> 
          <archive> 
            <manifest> 
              <addClasspath>true</addClasspath> 
              <addDefaultImplementationEntries>true</addDefaultImplementationEntries> 
              <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries> 
            </manifest> 
          </archive> 
        </configuration> 
      </plugin>
      -->
      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>nexus-staging-maven-plugin</artifactId>
        <version>1.6.5</version>
        <extensions>true</extensions>
        <configuration>
          <serverId>ossrh</serverId>
          <nexusUrl>https://oss.sonatype.org/</nexusUrl>
          <autoReleaseAfterClose>false</autoReleaseAfterClose>
        </configuration>
      </plugin>
    </plugins>
    
    <resources>
      <resource>
        <directory>src/main/resources</directory>
      </resource>
      <resource>
        <directory>src/main/resources</directory>
        <filtering>true</filtering>
        <includes>
          <include>**/BuildInfo.properties</include>
        </includes>
      </resource>
    </resources>
  </build>
  
  <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-project-info-reports-plugin</artifactId>
        <version>2.7</version>
        <reportSets>
          <reportSet>
            <reports>
              <!-- 
              See https://maven.apache.org/plugins/maven-project-info-reports-plugin/ 
              -->
              <report>index</report>
              <report>help</report>
              <report>plugin-management</report>
              <report>distribution-management</report>
              <report>dependency-info</report>
              <report>mailing-list</report>
              <report>issue-tracking</report>
              <report>plugins</report>
              <report>license</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>     
    </plugins>
  </reporting>
  
  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>com.cyc</groupId>
        <artifactId>cyc-session</artifactId>
        <version>1.0.0-rc1</version>
      </dependency>
      <dependency>
        <groupId>com.cyc</groupId>
        <artifactId>cyc-base-client</artifactId>
        <version>1.0.0-rc1</version>
      </dependency>
      <dependency>
        <groupId>com.cyc</groupId>
        <artifactId>cyc-kb</artifactId>
        <version>1.0.0-rc1</version>
      </dependency>
      <dependency>
        <groupId>com.cyc</groupId>
        <artifactId>cyc-query</artifactId>
        <version>1.0.0-rc1</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>[4.10,)</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>1.7.5</version>
      </dependency>
      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-log4j12</artifactId>
        <version>1.7.5</version>
      </dependency>
      <dependency>
        <groupId>log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.17</version>
      </dependency>
      <dependency>
        <groupId>org.atteo.classindex</groupId>
        <artifactId>classindex</artifactId>
        <version>3.1</version>
      </dependency>
    </dependencies>
  </dependencyManagement>
  
  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>
    
    <!-- 
      Used to gather up all classes with annotations, particularly the CycObjectLibraries - nwinant, 2014-08-07
    -->
    <dependency>
      <groupId>org.atteo.classindex</groupId>
      <artifactId>classindex</artifactId>
    </dependency>
    
    <!-- 
         Enables test-scope logging of Cyc APIs via SLF4J & Log4J. (Cyc APIs use
         SLF4J, which must be bound to a logging framework at deployment time.)
         
         Note that each API project maintains its own log4j.properties file in
         its src/test/resources directory.
         
       See:
       * http://www.slf4j.org/manual.html
       * [PROJECT]/src/test/resources/log4j.properties
    -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-log4j12</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>log4j</groupId>
      <artifactId>log4j</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>
 
</project>
