- Android environment setup
- Accept Android SDK license (via Terminal:
$ANDROID_HOME/tools/bin/sdkmanager --licenses) - Make keys (see this video)
- Build and Run
| Term | Definition |
|---|---|
SDK |
Software Development Kit, stored in /Users/<username>/Library/Android/sdk |
JDK |
Java Development Kit, stored in /Library/Java/JavaVirtualMachines/jdk1.8.0_144.jdk/Contents/Home |
NDK |
Native Development Kit, stored in /Users/<username>/Library/Android/android-ndk-r10e |
Gradle |
Gradle is an Android build system which automates a number of build processes. |
- Connect the Unity Profiler (setup instructions)
- Run the Android Device Monitor using Terminal
/Users/owmundy/Library/Android/sdk/tools/monitoror through the Android SDK Tools - Install and use ADB using Terminal
- view devices
adb devices - get pid for app
adb shell ps | grep <app name> - display log (filters for only Unity)
adb [logcat](https://developer.android.com/studio/command-line/logcat) -s Unity - display log (other filters)
adb [logcat](https://developer.android.com/studio/command-line/logcat) -s Unity ActivityManager PackageManager DEBUG - save log to file
adb [logcat](https://developer.android.com/studio/command-line/logcat) -s Unity ActivityManager PackageManager dalvikvm DEBUG > logcat.txt
- view devices
- You can download Android Studio to manage SDKs, etc., however (as of Jan 2019) Unity requires >= r13e when using IL2CPP
- Check that AndroidManifest files are the same version.
- Errors mentioning
arryoutfoindex- See this StackOverflow question - Errors mentioning
Package signatures do not match the previously ...- You have switched signatures (likely by changing to/from development build) and your original build is not 100% deinstalled on the Android device. See this StackOverflow question for a solution.
