My maven dependency is resolved, but not compiled. How do I debug?

So I have an android project and I've successfully resolved the support libraries (v4 and v7). You don't necessarily need to program Android to answer this question - suffice to say that v7-support-library has a class named android.support.v7.app.AppCompatActivity which is not found in the editor nor while compiling. The dependency is an .aar file, which is like .jar but with extra resources which are not classes. I'm using IntelliJ IDEA 14.0.2 and I believe it supports .aar dependencies just as well as Android Studio (correct me if I'm wrong).

So this is the Maven Projects tab:

1.png

My pom.xml is here

A suspicious thing is that in my project settings, neither of the support libraries are listed:
5.png

..and the list of External Libraries in the Project tab. Not listed here either:
4.png

...and the program does not compile:
2.png

So what am I doing wrong? What can I do to debug this error? I've looked at the idea.log file without getting any closer. I really want the dependency as a maven dependency (I know I have some dependencies still as old-fashiend .jar file references, but I'm in the process of converting the project), and I also know Android developers successfully are doing this with Maven, although most of them are using Gradle at this moment. Please help.

0

Please check if it works in 14.1.2 release.

https://youtrack.jetbrains.com/issue/IDEA-133282 may be related. Feel free to submit a new bug at http://youtrack.jetbrains.com/issues/IDEA if you have a sample project to reproduce this problem.

0

Ok, do you know if I can upgrade my ultimate release to 14.1.2 even though my upgrade license has expired?

0

If your license has expired before 14.1 release, you can't upgrade for free, sorry.

0

I was able to install v14.1.2. It did not solve the problem but I fixed the issue by including different instance of the same dependency:

 
<dependency>
    <groupId>android.support</groupId>
    <artifactId>compatibility-v7-appcompat</artifactId>
    <version>22.1.1</version>
    <type>apklib</type>
    <scope>compile</scope>
</dependency>
<dependency>
    <groupId>android.support</groupId>
    <artifactId>compatibility-v7-appcompat</artifactId>
    <version>22.1.1</version>
    <type>jar</type>
    <scope>compile</scope>
</dependency>
0

Turns out I couldn't reproduce the working solution on a second machine, so I opened an issue:

https://youtrack.jetbrains.com/issue/IDEA-139878

0

请先登录再写评论。