If needed, also set ANDROID_HOME environment variable like: export ANDROID_HOME=/path/to/android-sdk If you check the android-sdk folder after running tools/bin/sdkmanager -update it will be like: +- android-sdk The sdkmanager accepts the following flag: -sdk_root=: Use the specified SDK root instead of the SDKīut if we omit this flag, it assumes parent directory of tools directory as the sdk root, here in our case android-sdk directory. To get the SDK packages we could run: tools/bin/sdkmanager -update This extracts content to a single directory named tools, like: +- android-sdk Sdk-tools-linux-*.zip only includes the command-line tools. Tools/bin/sdkmanager "platform-tools" "platforms android–27" "build-tools 27.0.3" You can also use the sdkmanager to list and to install any specific packages needed. That's it! It should work to build now without errors.When executing the above commands, make sure that you replace * with an appropriate version number which you could find in the download page. Unity's manual for Android environment setup.SDK Platform Tools version 0.0.0 Preferences) and uncheck the Android SDK Tools Installed with Unity checkbox and type in the path to your Android SDK Tools folder, i.e.When building for Android I kept getting errors like: With the introduction of Unity Hub I've been struggling to get all the diferent versions of Unity to work with my Android SDK tools (which I have installed seperately). Disclaimer: This guide is only tried on Windows 10, but it might even work on Mac and Linux.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |