<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">
  <parent>
    <groupId>org.mortbay.jetty</groupId>
    <artifactId>modules-server</artifactId>
    <version>7.0.0.pre5</version>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <artifactId>jetty-xml</artifactId>
  <name>Jetty :: XML utilities</name>
  <description>The jetty xml utilities.</description>
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <executions>
          <execution>
            <id>copyfiles</id>
            <phase>install</phase>
            <goals>
              <goal>run</goal>
            </goals>
            <configuration>
              <tasks>
                <copy failonerror="false" file="target/${project.artifactId}-${project.version}.${project.packaging}" todir="../../../lib" />
              </tasks>
            </configuration>
          </execution>
          <execution>
            <id>clean</id>
            <phase>clean</phase>
            <goals>
              <goal>run</goal>
            </goals>
            <configuration>
              <tasks>
                <delete failonerror="false" file="../../../lib/${project.artifactId}-${project.version}.${project.packaging}" />
              </tasks>
            </configuration>
          </execution>		  
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <extensions>true</extensions>
        <executions>
          <execution>
            <goals>
              <goal>manifest</goal>
            </goals>
            <configuration>
              <instructions>
                <Bundle-SymbolicName>org.mortbay.xml</Bundle-SymbolicName>
                <Bundle-RequiredExecutionEnvironment>J2SE-1.5</Bundle-RequiredExecutionEnvironment>
                <Export-Package>org.mortbay.xml;version=${project.version}</Export-Package>
                <Bundle-DocURL>http://jetty.mortbay.org</Bundle-DocURL>
              </instructions>
            </configuration>
           </execution>
        </executions>
      </plugin>
      <plugin>
        <!--
        Required for OSGI
        -->
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <archive>               
            <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
          </archive>
        </configuration>
      </plugin>
      <!-- always include sources since jetty-xbean makes use of them -->
       <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>
        <artifactId>maven-assembly-plugin</artifactId>
        <configuration>
           <descriptors>
            <descriptor>src/main/assembly/site-component.xml</descriptor>
          </descriptors>
        </configuration>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>single</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <dependencies>
    <dependency>
      <groupId>org.mortbay.jetty</groupId>
      <artifactId>jetty-util</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>
</project>
