Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unity3D and AAR

Has anyone found a good way to utilize Android .aar libraries within Unity3D, other than unzipping them?

Snippets from the Unity 4.2 Release Notes:

  • Android: Added support for Android Library Projects (no compilation support, so the libraries have to be pre-compiled).
  • Android: Remove Eclipse project support in favor of Android project support.
  • Android: Support for Android SDK rev22.

The Unity documentation clarifies

Pre-compiled means all .java files must have been compiled into jar files located in either the bin/ or the libs/ folder of the project.

I'm familiar with using the jar + res/ solution; but I am specifically trying to identify the best way of incorporating the precompiled aar. Is there something better than unzipping it?

like image 612
Malachi Avatar asked May 07 '14 21:05

Malachi


1 Answers

With Unity 5, just place .aar files in the project. (They don't even need to be in /Plugins/Android anymore, just check the inspector and make sure they are turned on for Android platform).

like image 128
Clay Fowler Avatar answered Oct 03 '22 15:10

Clay Fowler