Android studio @aar import creating wrong directory with parsed code

So, hereโ€™s what, I have a .aar file, and when I add it as a dependency as follows:

compile('com.foo:bar: 1.0.0@aar ')

It generates the following file:

build > intermediates > exploded-aar > com.foo > bar > bar-1.0.0

which contains .jar classes, sources, etc.

However, SHOULD do the following:

build > intermediates > exploded-aar > com.foo > bar > 1.0.0

Does anyone know why my avar is not being imported correctly?

This is a problem since when creating gradle:

The following error occurs:

com.android.manifmerger.ManifestMerger2$MergeFailureException: java.io.FileNotFoundException: /build/intermediates/exploded-aar/com.foo/bar/1.0.0/AndroidManifest.xml (No such file or directory)

However, it is clearly visible in the bar-1.0.0 directory.

Edit: more details

  • Tested on 5 machines. All running AS 0.8.9, fresh installations, fresh clone.
  • Checked by Jdk 1.6 and 1.7.
  • - Updates called to ensure that all changes have been compiled.

Nothing works.

+5
source share
1 answer

I was not going to answer my question, but now I want to get a few votes.

It turned out that minSDK, which was defined in my build.gradle file, was not installed.

Once I installed the correct SDK, everything worked fine.

+3
source

Source: https://habr.com/ru/post/1202614/


All Articles