You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Manfred Wolff <mw...@neusta.de> on 2004/06/26 13:55:16 UTC
jar and ear both together
Hi
I have a project that builds a jar file a.jar *and* and ear file calls
a.ear. The ear file must contain the jar file.
<dependency>
<groupId>a</groupId>
<artifactId>a</artifactId>
<version>0.1-dev</version>
<type>jar</type>
<properties>
<ear.bundle>true</ear.bundle>
</properties>
</dependency>
This dependency crashes by building the jar file, because the jar will
be created with the jar:jar goal. The jar goal will dissolve the
dependency and finds not the a-0.1-dev.jar, because he will create it.
After that I call the ear:ear goal and will include the jar just been
created. Has anyone a solution for this.
I need dependencies that are only valid for specific goals like
<dependency>
<goals>
<goal>ear</goal>
</goals>
<groupId>a</groupId>
<artifactId>a</artifactId>
<version>0.1-dev</version>
<type>jar</type>
<properties>
<ear.bundle>true</ear.bundle>
</properties>
</dependency>
Manfred
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: jar and ear both together
Posted by "matthew.hawthorne" <ma...@apache.org>.
Dion Gillard wrote:
> A project should create either a jar, or an ear, not both. Split it up
> into two projects.....
I agree that this is the easiest way. However, I once created a project
that built and ejb jar, a war, and an ear. It involved a preGoal to
ear:ear which created the war and jar, and then a postgoal which
unpacked the new ear and put the jar and war inside of it. Ugly, yes...
but it worked.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: jar and ear both together
Posted by Dion Gillard <di...@gmail.com>.
A project should create either a jar, or an ear, not both. Split it up
into two projects.....
On Sat, 26 Jun 2004 13:55:16 +0200, Manfred Wolff <mw...@neusta.de> wrote:
>
> Hi
>
> I have a project that builds a jar file a.jar *and* and ear file calls
> a.ear. The ear file must contain the jar file.
>
> <dependency>
> <groupId>a</groupId>
> <artifactId>a</artifactId>
> <version>0.1-dev</version>
> <type>jar</type>
> <properties>
> <ear.bundle>true</ear.bundle>
> </properties>
> </dependency>
>
> This dependency crashes by building the jar file, because the jar will
> be created with the jar:jar goal. The jar goal will dissolve the
> dependency and finds not the a-0.1-dev.jar, because he will create it.
> After that I call the ear:ear goal and will include the jar just been
> created. Has anyone a solution for this.
>
> I need dependencies that are only valid for specific goals like
>
> <dependency>
> <goals>
> <goal>ear</goal>
> </goals>
> <groupId>a</groupId>
> <artifactId>a</artifactId>
> <version>0.1-dev</version>
> <type>jar</type>
> <properties>
> <ear.bundle>true</ear.bundle>
> </properties>
> </dependency>
>
> Manfred
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org