Browse Source

Add minimal details required to successfully Export to Android (#3066)

Co-authored-by: Hugo Locurcio <[email protected]>
Jason Swearingen 5 years ago
parent
commit
56e5baffdf
1 changed files with 19 additions and 10 deletions
  1. 19 10
      getting_started/workflow/export/exporting_for_android.rst

+ 19 - 10
getting_started/workflow/export/exporting_for_android.rst

@@ -3,20 +3,24 @@
 Exporting for Android
 =====================
 
-Exporting for Android has fewer requirements than compiling Godot for it. The
-following steps detail what is needed to setup the SDK and the engine.
+Exporting for Android has fewer requirements than compiling Godot for it.
+The following steps detail what is needed to setup the SDK and the engine.
 
 Download the Android SDK
 ------------------------
 
 Download and install the Android SDK from
-https://developer.android.com/studio/
+`developer.android.com <https://developer.android.com/studio/>`__.
+
+If you install Android Studio, you need to run it once to complete the SDK setup.
 
 Install OpenJDK or Oracle JDK
 -----------------------------
 
 Download and install  `OpenJDK <https://github.com/ojdkbuild/ojdkbuild>`__ or `Oracle JDK <http://www.oracle.com/technetwork/java/javase/downloads/index.html>`__. Versions below JDK 8 may not work; some users have reported issues with the jarsigner (used to sign the APKs) in JDK 7.
 
+If you install OpenJDK, choose ``1.8``. Don't choose the ``openjdk-jre`` files as that only contains the JRE, not the JDK which is required here.
+
 Create a debug.keystore
 -----------------------
 
@@ -26,16 +30,16 @@ projects, ant or eclipse probably generated one for you (on Linux and
 macOS, you can find it in the ``~/.android`` directory).
 
 If you can't find it or need to generate one, the keytool command from
-the JDK can be used for this purpose:
-
-::
+the JDK can be used for this purpose::
 
     keytool -keyalg RSA -genkeypair -alias androiddebugkey -keypass android -keystore debug.keystore -storepass android -dname "CN=Android Debug,O=Android,C=US" -validity 9999
 
+This will create a ``debug.keystore`` file in your current directory. You should move it to a memorable location such as ``%USERPROFILE%\.android\``, because you will need its location in a later step. For more information on ``keytool`` usage, see `this Q&A article <https://godotengine.org/qa/21349/jdk-android-file-missing>`__.
+
 Make sure you have adb
 ----------------------
 
-Android Debug Bridge (adb) is the command line tool used to communicate with
+Android Debug Bridge (``adb``) is the command line tool used to communicate with
 Android devices. It's installed with the SDK, but you may need to install one
 (any) of the Android API levels for it to be installed in the SDK directory.
 
@@ -54,9 +58,14 @@ Scroll down to the section where the Android settings are located:
 
 In that screen, the path to 3 files needs to be set:
 
--  The *adb* executable (adb.exe on Windows)
--  The *jarsigner* executable (from JDK 6 or 8)
--  The debug *keystore*
+- The ``adb`` executable (``adb.exe`` on Windows)
+  - It can usually be found at ``%LOCALAPPDATA%\Android\Sdk\platform-tools\adb.exe``.
+
+- The ``jarsigner`` executable (from JDK 6 or 8)
+  - On Windows, OpenJDK installs to a dir like ``%PROGRAMFILES%\ojdkbuild\java-1.8.0-openjdk-1.8.0.232-2\bin``. The exact path may vary depending on the OpenJDK update you've installed.
+
+- The debug ``.keystore`` file
+  - It can be found in the folder where you put the ``debug.keystore`` file you created above.
 
 Once that is configured, everything is ready to export to Android!