On Wed, Apr 6, 2011 at 11:06 AM, Adam Gibbons <adam.s.gibb...@gmail.com> wrote:
> Yes,
>
>  +-- pom.xml
>  +-- m1 (j1, j2)
>  +-- m2 (j3)
>  +-- m3 (j1, j3)
>  +-- m4
>  +-- m5
>  +-- j1
>  +-- j2
>  +-- j3
>  +-- war1 (m1,m2,m3)
>  +-- war2 (m4)
>  +-- war3 (m5)
>
> This setup is effectively what I have so far.
> However I am unable to use parent on a number of modules (as some have more
> than 1). On reading the doco I don't believe this actually matters.

Each pom should have a <parent> pointing to the pom in the directory
above it.  That pom should have <modules> pointing down to its
subdirectories.

Whatever you're doing that makes you think a module has more than one
parent is likely the cause of the confusion.

> Am I right in thinking that the root pom only need include the war modules
> and everything else should be taken care of?

No, the root pom needs to include  a <module> element for each
subdirectory.  Including the jars.

>I guess the main issue I'm
> having trouble wrapping my head around is if doing a package from the top
> level pom, how and when to jars get compiled/deployed and what do you need
> to do to achieve this?

List them all as modules.  (Assuming they are subdirectories.  The
hierarchy can actually be more complex with levels of parents, but for
now I'd get it working as a flatter structure with a single parent
that lists all of your modules.  Then refactor later if you find
duplication.)

-- 
Wendy

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to