2

I have a project that uses gwt and has dependencies to several components in my company's svn. In my MainApp.gwt.xml I inherit those modules. The problem is, that one of those seems not to be a gwt module, so I get this error:

ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] GWT Module com.sample.project.sample-module-b not found in project sources or resources. 

But I also can't just delete it, since there is another module, that needs sources from this module-b. If I delete the line

<inherits name="com.sample.project.sample-module-b"/>

from my MainApp.gwt.xml I get the following error:

[ERROR] Errors in 'jar:file:/C:/pathToRepository/com/sample/project/sample-module-a/0.1-SNAPSHOT-sources.jar!/com/sample/project/a/to/ClassA.java'
   [ERROR] Line 23: No source code is available for type com.sample.project.module-b.ClassB; did you forget to inherit a required module?

I added both module-a and module-b to my maven-dependencies, but that didn't do the trick. Is there any possibility to inherit that module althogh it's not a gwt module? My own classes never use module-b directly, just in this dependency. How do I tell module-a or my MainApp to use sources from module-b without treating it as gwt module? Hopefully anybody kann give me a hint. Best regards, Kayz

Kayz
  • 637
  • 1
  • 8
  • 21
  • 1
    You need to inherit the module if you use that code in client side. So it's better for you to declare sample-module-b as gwt module by adding gwt.xml – Bitman Jun 21 '13 at 13:24
  • I can't do that, since module-a and module-b are not under my controll, they are someone elses components. But I will ask him to do that, thanks. – Kayz Jun 21 '13 at 13:43
  • 1
    @IvanM Your solution did work for me. I 'cheated' a little. Under my MainApp src/main/resources folder I put the folder structure com.sample.project. In that project folder I created the module-b.gwt.xml file. Thanks a lot for the hint! – Kayz Jun 21 '13 at 14:13
  • 1
    I don't get why people don't just put their answer in the answer section.... – aglassman Jun 24 '13 at 17:46

1 Answers1

0

To solve this problem I had to do the following: Under my MainApp src/main/resources folder I put the folder structure com.sample.project. In that folder I created the file module-b.gwt.xml and everything worked fine.

Kayz
  • 637
  • 1
  • 8
  • 21