I've been wondering this myself and just "didn't care" enough to really solve the "problem". ;-)
Fortunately the duplicated libs are not very large so it doesn't affect me much (yet). Anyone got a solution? Wayne On 3/22/06, Richard Sladek <[EMAIL PROTECTED]> wrote: > > Hello, > I've been searching through the archive half of the day but I haven't found > a satisfactory solution to my problem: > I have an EAR including 2 modules: EJB JAR and WAR. > These 2 modules have some common dependencies, lets say mycommonlib.jar. > > When I run the packaging on EAR, I get duplicates of mycommonlib.jar: > one is in EAR's root, the other is in WAR's WEB-INF/lib. > > I found a way how to exclude this from WEB-INF/lib by providing: > <plugin> > <groupId>org.apache.maven.plugins</groupId> > <artifactId>maven-war-plugin</artifactId> > <configuration> > <warSourceExcludes>WEB-INF/lib/*.jar</warSourceExcludes> > <archive> > <manifest> > <addClasspath>true</addClasspath> > <classpathPrefix>/</classpathPrefix> > </manifest> > </archive> > </configuration> > </plugin> > in my WAR's pom.xml > > However, now none of my WAR's dependencies gets resolved to the EAR (see > http://jira.codehaus.org/browse/MEAR-14), even those that are not common. > Is there a way how could I force EAR plugin to enable transitive > dependencies on a WAR? > > Also see > http://jira.codehaus.org/browse/MWAR-9 > -- > View this message in context: > http://www.nabble.com/M2---Best-practice-for-common-jars-between-EJB%2CWAR-modules-in-EAR-t1325601.html#a3537700 > Sent from the Maven - Users forum at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
