<?xml version="1.0"?>
<!--
  Licensed to the Apache Software Foundation (ASF) under one
  or more contributor license agreements. See the NOTICE file
  distributed with this work for additional information
  regarding copyright ownership. The ASF licenses this file
  to you under the Apache License, Version 2.0 (the
  "License"); you may not use this file except in compliance
  with the License. You may obtain a copy of the License at
 
  http://www.apache.org/licenses/LICENSE-2.0
 
  Unless required by applicable law or agreed to in writing,
  software distributed under the License is distributed on an
  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  KIND, either express or implied. See the License for the
  specific language governing permissions and limitations
  under the License.
-->
<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.apache.cxf.fediz</groupId>
        <artifactId>plugin</artifactId>
        <version>1.1.3</version>
        <relativePath>../pom.xml</relativePath>
    </parent>
    <artifactId>fediz-jetty</artifactId>
    <name>Apache Fediz Plugin Jetty</name>
    <packaging>bundle</packaging>
    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>
    <dependencies>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-server</artifactId>
            <version>${jetty.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-security</artifactId>
            <version>${jetty.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-xml</artifactId>
            <version>${jetty.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-webapp</artifactId>
            <version>${jetty.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-jsp</artifactId>
            <version>${jetty.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.cxf.fediz</groupId>
            <artifactId>fediz-core</artifactId>
            <version>${project.version}</version>
            <type>jar</type>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpclient</artifactId>
            <version>${httpclient.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>net.htmlparser.jericho</groupId>
            <artifactId>jericho-html</artifactId>
            <version>${jericho.version}</version>
            <scope>test</scope>
        </dependency>
        <!-- 
                <dependency>
                        <groupId>javax.servlet.jsp</groupId>
                        <artifactId>jsp-api</artifactId>
                        <version>2.2.1-b03</version>
                </dependency>
                <dependency>
                        <groupId>org.glassfish.web</groupId>
                        <artifactId>jsp-impl</artifactId>
                        <version>2.2.2-b06</version>
                </dependency>
                <dependency>
                        <groupId>org.apache.geronimo.ext.tomcat</groupId>
                        <artifactId>jasper-el</artifactId>
                        <version>7.0.19.2</version>
                </dependency>
                <dependency>
                        <groupId>org.apache.geronimo.bundles</groupId>
                        <artifactId>jstl</artifactId>
                        <version>1.2_1</version>
                </dependency>
                <dependency>
                        <groupId>org.apache.geronimo.specs</groupId>
                        <artifactId>geronimo-servlet_3.0_spec</artifactId>
                        <version>1.0</version>
                </dependency>
 -->
    </dependencies>
    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>2.4</version>
                <executions>
                    <execution>
                        <id>zip-file</id>
                        <phase>package</phase>
                        <goals>
                            <goal>attached</goal>
                        </goals>
                        <configuration>
                            <descriptors>
                                <descriptor>src/main/assembly/assembly.xml</descriptor>
                            </descriptors>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <version>2.4.0</version>
                <extensions>true</extensions>
                <configuration>
                    <instructions>
                        <Implementation-Title>Apache CXF Fediz</Implementation-Title>
                        <Implementation-Vendor>The Apache Software Foundation</Implementation-Vendor>
                        <Implementation-Vendor-Id>org.apache</Implementation-Vendor-Id>
                        <Implementation-Version>${project.version}</Implementation-Version>
                        <Specification-Title>Apache CXF Fediz</Specification-Title>
                        <Specification-Vendor>The Apache Software Foundation</Specification-Vendor>
                        <Specification-Version>${project.version}</Specification-Version>
                        <Export-Package>
                            org.apache.cxf.fediz.jetty.*;version="${project.version}"
                        </Export-Package>
                        <Import-Package>
                            !org.apache.cxf.fediz.jetty*,
                            org.eclipse.jetty.*;version="[7.6,9)",
                            org.apache.cxf.fediz.core.*,
                            *;resolution:=optional
                        </Import-Package>
                    </instructions>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>2.8</version>
                <executions>
                    <execution>
                        <id>copy-idp-sts</id>
                        <phase>generate-resources</phase>
                        <goals>
                            <goal>copy</goal>
                        </goals>
                        <configuration>
                            <artifactItems>
                                <artifactItem>
                                    <groupId>org.apache.cxf.fediz</groupId>
                                    <artifactId>fediz-idp</artifactId>
                                    <version>${project.version}</version>
                                    <type>war</type>
                                    <overWrite>true</overWrite>
                                </artifactItem>
                                <artifactItem>
                                    <groupId>org.apache.cxf.fediz</groupId>
                                    <artifactId>fediz-idp-sts</artifactId>
                                    <version>${project.version}</version>
                                    <type>war</type>
                                    <overWrite>true</overWrite>
                                </artifactItem>
                            </artifactItems>
                            <outputAbsoluteArtifactFilename>true</outputAbsoluteArtifactFilename>
                            <outputDirectory>target</outputDirectory>
                            <overWriteSnapshots>true</overWriteSnapshots>
                            <overWriteIfNewer>true</overWriteIfNewer>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
</project>
