• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

m2eclipse and Maven Multi Module Projects

 
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
I am using the m2eclipse plugin in Eclipse and try to develop a multi-module Maven project, which I then want to package to a distribution directory.
I would like to ask if anyone had any success with the following, or similar, scenario:
- One Parent Maven project.
- One Library Maven module in the Parent project.
- One Application Maven module in the Parent project.
- A dependency from the Application module to the Library module.
- The following plugins in the Application module:


When trying to package the Application module, I get the following error:


The following mojo encountered an error while executing:
Group-Id: org.apache.maven.plugins
Artifact-Id: maven-dependency-plugin
Version: 2.0
Mojo: copy
brought in via: POM

While building project:
Group-Id: com.ivan.maven_multimodule
Artifact-Id: Application
Version: 0.0.1
From file: /Users/Shared/EclipseWorkspace/Parent/Application/pom.xml
Reason: Error copying artifact from /Users/Shared/EclipseWorkspace/Parent/Application/target/classes to /Users/Shared/EclipseWorkspace/Parent/Application/target/dist/classes


Many thanks in advance!
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ivan!
I have been thinking a little about your problem.
I think the problem is caused by the artifact not being packaged when trying to copy it in the packaging phase.
If I have understand it correct, this is something that should be done in the assembly phase, correct?
I have myself encountered another problem; if I have a project A that has a dependency to project B and the project B artifact is NOT installed in the repository, the project B JAR will not show up in the project A JAR manifest. I don't want a binary dependency on the project B, but a dependency within Eclipse, so that, as soon as I change the project B, project A will use the latest version of project B when being executed in the Eclipse workspace.
At the same time, I want to be able to automatically create a distribution directory or archive, with all dependecies (classpaths) set.
Good luck!
 
My cellmate was this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic