<?xml version="1.0" encoding="UTF-8"?>
<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>org.richfaces</groupId>
		<artifactId>seamApp</artifactId>
		<version>1.0-SNAPSHOT</version>
	</parent>
	<artifactId>${projectName}-ear</artifactId>
	<name>EAR module</name>
	<packaging>ear</packaging>
	<dependencies>
		<dependency>
			<groupId>javax.el</groupId>
			<artifactId>el-api</artifactId>
			<version>1.0</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.richfaces</groupId>
			<artifactId>${projectName}-web</artifactId>
			<version>1.0-SNAPSHOT</version>
			<type>war</type>
			<exclusions>
				<exclusion>
					<artifactId>el-api</artifactId>
					<groupId>javax.el</groupId>
				</exclusion>
			</exclusions>
		</dependency>		

        <!-- EJB -->
		<dependency>
			<groupId>org.jboss.seam</groupId>
			<artifactId>jboss-seam</artifactId>
			<version>${seamVersion}</version>
			<exclusions>
				<exclusion>
					<artifactId>el-api</artifactId>
					<groupId>javax.el</groupId>
				</exclusion>
				<exclusion>
					<groupId>org.jboss.seam</groupId>
					<artifactId>jboss-el</artifactId>
				</exclusion>
				<exclusion>
					<groupId>commons-collections</groupId>
					<artifactId>commons-collections</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.jboss.seam</groupId>
					<artifactId>jboss-seam-pdf</artifactId>
				</exclusion>
				<exclusion>
					<groupId>dom4j</groupId>
					<artifactId>dom4j</artifactId>
				</exclusion>
				<exclusion>
					<groupId>jboss</groupId>
					<artifactId>javassist</artifactId>
				</exclusion>
				<exclusion>
					<groupId>xerces</groupId>
					<artifactId>xercesImpl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>xml-apis</groupId>
					<artifactId>xml-apis</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.richfaces</groupId>
			<artifactId>${projectName}-ejb</artifactId>
			<version>1.0-SNAPSHOT</version>
			<type>ejb</type>
			<exclusions>
				<exclusion>
					<artifactId>servlet-api</artifactId>
					<groupId>javax.servlet</groupId>
				</exclusion>
				<exclusion>
					<artifactId>jsf-api</artifactId>
					<groupId>javax.faces</groupId>
				</exclusion>
				<exclusion>
					<artifactId>jsf-impl</artifactId>
					<groupId>javax.faces</groupId>
				</exclusion>
				<exclusion>
					<artifactId>el-api</artifactId>
					<groupId>javax.el</groupId>
				</exclusion>
				<exclusion>
					<artifactId>javassist</artifactId>
					<groupId>jboss</groupId>
				</exclusion>
				<exclusion>
					<groupId>org.jboss.seam</groupId>
					<artifactId>jboss-seam</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.richfaces.framework</groupId>
					<artifactId>richfaces-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.richfaces.framework</groupId>
					<artifactId>richfaces-impl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.richfaces.ui</groupId>
					<artifactId>richfaces-ui</artifactId>
				</exclusion>
				<exclusion>
					<groupId>xml-apis</groupId>
					<artifactId>xml-apis</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.jboss.seam</groupId>
			<artifactId>jboss-el</artifactId>
			<version>2.0.0.GA</version>
			<exclusions>
				<exclusion>
					<artifactId>el-api</artifactId>
					<groupId>javax.el</groupId>
				</exclusion>
			</exclusions>
		</dependency>		
	</dependencies>
	<build>
		<finalName>${projectName}-ear-1.0-SNAPSHOT</finalName>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-ear-plugin</artifactId>
				<version>2.3.1</version>
				<configuration>
					<generateApplicationXml>true</generateApplicationXml>
					<includeJar>false</includeJar>
					<defaultLibBundleDir>lib</defaultLibBundleDir>
					<loader-repository>seam.jboss.org:loader=${project.build.finalName}</loader-repository>
					<modules>
						<webModule>
							<groupId>org.richfaces</groupId>
							<artifactId>${projectName}-web</artifactId>
							<contextRoot>/${projectName}</contextRoot>
						</webModule>
						<ejbModule>
							<groupId>org.richfaces</groupId>
							<artifactId>${projectName}-ejb</artifactId>
						</ejbModule>
					</modules>
				</configuration>
			</plugin>
			<!--plugin>
                <groupId>org.codehaus.cargo</groupId>
                <artifactId>cargo-maven2-plugin</artifactId>
				<version>1.0-SNAPSHOT</version>
                <executions>
                    <execution>
                        <phase>pre-integration-test</phase>
                        <goals>
							<goal>deployer-deploy</goal>
                        </goals>
                    </execution>
					<execution>
						<id>start-container</id>
						<phase>pre-integration-test</phase>
						<goals>
						<goal>start</goal>
						</goals>
					</execution>
                </executions>
                <configuration>
                    <container>
                        <containerId>jboss4x</containerId>
                        <zipUrlInstaller>
						<url>${jbossDownloadURL}</url>
						<installDir>${installDir}</installDir>
						</zipUrlInstaller>
                        <output>${project.build.directory}/jboss4x.log</output>
                        <log>${project.build.directory}/cargo.log</log>
						</container>
							<configuration>
                                <type>existing</type>
								<home>${installDir}/${jbossDeployDir}</home>
                                <properties>
                                    <cargo.servlet.port>8080</cargo.servlet.port>
									<cargo.jboss.configuration>default</cargo.jboss.configuration>
                                </properties>
                            </configuration>
                </configuration>
            </plugin-->
		</plugins>
	</build>
</project>
