Problem with Android libraries in IntelliJ 10.5

  Forgive me if I am doing something dumb, but I am having a right old game trying to get some Android libraries I created working in IntelliJ.  (I have come from Eclipse, which drove me nuts).

I have seen this rather good wiki page: http://wiki.jetbrains.net/intellij/Sharing_and_re-using_Android_resources_through_library_projects  But it's not helping me.

My problem is that the libraries appear to compile correctly when they are opened as their own project, but when they are used in my main project, I get problems with missing depdancies (the libraries themselves have dependancies, but these appear to be setup correctly, as the project compiles when opened individually).

Information:Compilation completed with 100 errors and 0 warnings
Information:100 errors
Information:0 warnings
D:\DEV\bg\src\com\mge\flybe\Parser.java
Error:Error:line (20)package org.jsoup does not exist
Error:Error:line (21)package org.jsoup.nodes does not exist
Error:Error:line (53)cannot find symbol class Document
  D:\DEV\bg\src\com\mge\flybe\Cleaner.java
Error:Error:line (24)package org.jsoup.nodes does not exist
Error:Error:line (25)package org.jsoup.nodes does not exist
Error:Error:line (26)package org.jsoup.nodes does not exist
Error:Error:line (27)package org.jsoup.nodes does not exist
Error:Error:line (28)package org.jsoup.select does not exist
Error:Error:line (29)package org.slf4j does not exist
Error:Error:line (30)package org.slf4j does not exist
Error:Error:line (58)cannot find symbol class Logger
Error:Error:line (89)cannot find symbol class Document
Error:Error:line (89)cannot find symbol class Document
Error:Error:line (118)cannot find symbol class Document
Error:Error:line (118)cannot find symbol class Document
Error:Error:line (185)cannot find symbol class Document
Error:Error:line (185)cannot find symbol class Document
Error:Error:line (206)cannot find symbol class Document
Error:Error:line (206)cannot find symbol class Document
Error:Error:line (339)cannot find symbol class Document
Error:Error:line (339)cannot find symbol class Document
Error:Error:line (361)cannot find symbol class Element
Error:Error:line (374)cannot find symbol class Document
Error:Error:line (374)cannot find symbol class Document
Error:Error:line (408)cannot find symbol class Document
Error:Error:line (408)cannot find symbol class Document




and so on.....

3 comments
Comment actions Permalink

Nobody???

I really can't figure out how to get my previously compiling Eclipse project to work in IntelliJ.   I really don't want to go back to Eclipse :-(

0
Comment actions Permalink

Are org.jsoup.* classes locates in some JAR file? Try to press Alt+Enter on error in editor. Does IDEA offer any fix?

0
Comment actions Permalink

Actually I had got the same problem. And I think that it is a bug in IDEA.It seems thad IDEA incorrectly process directories where the generated content is stored (R.class). To reproduce the problem you need instead of gen/ directory for R.class use custom folder. Say, we have two project: proj1(~/projects/proj1) and lib1(~/projects/lib1). By default destination directoris set for AAPT compiler are ~/projects/proj1/gen and ~/projects/lib1/gen. If you change them to another ones (as I did) you will get the error mentioned above.

0

Please sign in to leave a comment.