On Fri, Dec 16, 2011 at 5:24 AM, Daivish Shah <[email protected]> wrote:
> Hi Barrie Treloar,
>
> You suggestions looks good to me, I tried your suggestion.
>
> And yes this is not working only XSD generated import statements in Module
> 2. I have one DAO module too which is also generating some JAR file. And
> that is also imported in Module2 but that import statements doesn't show X
> as compilation error in Eclipse but i have only problem with XSD generated
> files with my Eclipse. If i execute mvn install from Top level it means
> MainProject then it doesn't show any compilation Error in execution log.

So, great that Maven is working properly.

> And yes XSD project is publishing JAR file and which is located under my
> local repository correctly. and it has all generated classes in it. So if i
> manually add that Depedancy in my Eclipse then all X sign as compilation
> error gone, But ideally it should not be Manual. If i define as Dependency
> it should automatically pickup that file.
>
> And this is only issue with Sub Module of Main Project and XSD module. And
> in MAVEN Dependency list it's showing as FOLDER icon and all other
> dependencies are showing as JAR icon and location of those JAR files are
> showing as my LOCAL Repository of MAVEN.
>
> I tried using  build-helper-maven-plugin but it doesn't help to resolve my
> COMPILATION error Icons in ECLIPSE so i am confused how to resolve this XSD
> related problem. If any other suggestion or advice will really appreciated.

This is not a Maven issue.  This is an Eclipse issue.

What are you using to configure Eclipse?
If you are using the maven-eclipse-plugin I can give guidance.
If you are using something else then I can't.

The first step is to manually fix the problem.
Which you appear to have done by manually adding the jar file as a dependency.

For my project, I am just manually adding the
target/<artifactId>-<version>.jar into that project's .classpath
(Right click the jar file > build path > add to build path)
And then export that jar file in the class file (Right click the
project > build path > configure build path > order and export tab >
enable jar > click ok)

I haven't bothered to find a way to automate this yet.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to