<?xml version="1.0" encoding="UTF-8"?>
<!--
      =======================================================================
        Maven Project Configuration File

        GeoSolutions GeoBatch Project
            http://geobatch.codehaus.org
      =======================================================================
-->
<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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>it.geosolutions.geobatch</groupId>
        <artifactId>gb</artifactId>
        <version>1.0</version>
    </parent>

    <!-- =========================================================== -->
    <!--     Module Description                                      -->
    <!-- =========================================================== -->
    <groupId>it.geosolutions.geobatch</groupId>
    <artifactId>gb-services</artifactId>
    <packaging>pom</packaging>

    <name>GeoBatch optional services</name>
    <description>GeoSolutions GeoBatch optional services</description>

    <url>http://www.geo-solutions.it/maven_reports/gb/flow-managers/</url>

    <scm>
        <connection>
            scm:svn:http://svn.geotools.org/geotools/trunk/gt/modules/flow-managers/
        </connection>
        <url>http://svn.geotools.org/geotools/trunk/gt/modules/flow-managers/</url>
    </scm>


    <licenses>
        <license>
            <name>Lesser General Public License (LGPL)</name>
            <url>http://www.gnu.org/copyleft/lesser.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>

                <inherited>true</inherited>

                <executions>
                    <!-- Remove the flowdata files from the base jar ========-->
                    <execution>
                        <!--
                          setting the phase as prep-pack is the only way I::etj found
                          to have the excludes work.
                          Once the basic jar is created with the exclusions,
                          the jar will not be rebuilt in the jar:jar phase.

                          This exclusion will work with maven 2.1.0 but not with 2.0.9 or 2.0.10.
                        -->
                        <phase>prepare-package</phase>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <configuration>
                            <excludes>
                                <exclude>data/</exclude>
                            </excludes>
                        </configuration>
                    </execution>

                    <!-- Creates a jar containing only the flowdata files ===-->
                    <execution>
                        <id>packFlowData</id>
                        <phase>package</phase>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <configuration>
                            <classifier>flowdata</classifier>
                            <includes>
                                <include>data/**</include>
                            </includes>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>

    <!-- =========================================================== -->
    <!--     Modules for the build in approximate dependency order   -->
    <!-- =========================================================== -->
    <profiles>    
	<profile>
            <id>jms</id>
            <activation>
                <property>
                    <name>all</name>
                    <value>true</value>
                </property>
            </activation>
            <modules>
                <module>jms</module>
            </modules>
        </profile>
        <profile>
            <id>octave</id>
            <activation>
                <property>
                    <name>all</name>
                    <value>true</value>
                </property>
            </activation>
            <modules>
		<module>octave</module>
            </modules>
        </profile>
    </profiles>
	
</project>
