Debian Codegraph @

DOC/BUILD.android

raw
1 Build instructions for the Android port
2 ---------------------------------------
3
4 If you are looking for instructions on how to use the Android port, what the
5 preferences mean etc. you should check out instead:
6
7 https://atari800.github.io/Atari800forAndroid.html
8
9 See also DOC/README.android.
10
11 I. Prerequisites
12 ----------------
13
14 To compile the Android port, you are going to need:
15
16 1. A working autotools/make environment (e.g. Cygwin or MinGW on Windows).
17
18 Before trying to build the Android port, it is a good idea to first try building
19 the desktop version, for instance the SDL port. It is a good way to verify that
20 the necessary tools are installed and working correctly. See DOC/INSTALL to
21 build Atari800 on Unix environments, or DOC/BUILD.windows to build under Cygwin
22 and MinGW.
23
24 2. The Java JDK.
25
26 Version 17 or later is recommended:
27
28 https://adoptium.net/
29
30 3. The Android SDK (command-line tools).
31
32 Install the Android command-line tools (cmdline-tools) from:
33
34 https://developer.android.com/studio#command-line-tools-only
35
36 Then use sdkmanager to install required packages:
37
38 # sdkmanager "platform-tools" "build-tools;36.0.0" "platforms;android-36" "cmake;3.22.1"
39
40 4. The Android NDK.
41
42 Install the NDK via sdkmanager:
43
44 # sdkmanager "ndk;27.0.12077973"
45
46 Or download it manually from:
47
48 https://developer.android.com/ndk/downloads
49
50 II. Setting up the environment
51 ------------------------------
52
53 1. Set the ANDROID_HOME environment variable to point to the SDK root, e.g.:
54
55 # export ANDROID_HOME=/path/to/android-sdk
56
57 2. Set the JAVA_HOME environment variable to point to your JDK, e.g.:
58
59 # export JAVA_HOME=/path/to/jdk-17
60
61 3. Add the Android SDK tools to PATH:
62
63 # export PATH="$ANDROID_HOME/cmdline-tools/latest/bin:$ANDROID_HOME/platform-tools:$PATH"
64
65 III. Compiling
66 --------------
67
68 1. Unpack the source tarball of Atari800.
69
70 2. If the configure script is missing, create it:
71
72 # ./autogen.sh
73
74 3. Configure the build:
75
76 # ./configure --target=android
77
78 4. Build the APK package:
79
80 # make
81
82 After a while, the APK package should appear in:
83
84 src/android/build/outputs/apk/debug/colleen-debug.apk
85
86 To build a release APK suitable for distribution:
87
88 # cd src/android && ./gradlew assembleRelease
89
90 You will need to configure signing in src/android/build.gradle.kts or supply
91 keystore properties via the command line.