We use an exclude rule for WEB-INF/lib/*.jar and a custom version of the
war plugin with MWAR-39 fixed. 

-----Original Message-----
From: Arthur Crawford [mailto:art&[EMAIL PROTECTED] 
Sent: Wednesday, June 07, 2006 3:02 AM
To: users@maven.apache.org
Subject: [m2] war plugin - need dependencies referenced in manifest but
not in WEB-INF/lib

Hi,
Is there a way to create a war with references to dependent jars in the
manifest's classpath entry but NOT package them in WEB-INF/lib?.  I want
to do this so I can have sevaral wars referencing the same shared jars
in the top level of an ear.

This is the war plugin configuration I have used to turn on manifest
generation.

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-war-plugin</artifactId>
                <version>2.0</version>
                <configuration>
                    <archive>
                        <manifest>
                            <addClasspath>true</addClasspath>
                        </manifest>
                    </archive>
                </configuration>
            </plugin>

Then I have tried <scope>provided</scope>.  But although the jars are
omitted from WEB-INF/lib as I want, neither do they appear the manifest.
Scope compile puts everything in the manifest but also in WEB-INF/lib.
Scope runtime has the same effect as scope compile (in this context).

I have looked through all the documentation and posts I can find on this
but have seen no solution.  It seems like a common thing to want to do
when packaging shared code in wars/ears.  If it's not possible with
Maven out-of-the-box does anyone have any suggested fix or workaround?

I'm using Maven version 2.0.4 - war plugin version 2.0

Regards,

Arthur Crawford.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to