- Android Java GUI — located in
client/Android/Studio - Native FreeRDP libraries — built with the Android NDK and CMake
- JNI bindings —
client/Android/android_freerdp.cand the corresponding Java classLibFreeRDP.java
More documentation may be found at the FreeRDP Compilation wiki.
Build requirements
For the native JNI libraries
- CMake >= 3.13 — install via Android SDK Manager (SDK Tools section)
- Android NDK >= r15c
For the Java GUI
- Android SDK
- Android Studio (recommended) or Gradle
Optional dependencies
- cJSON — required for logging in to Azure accounts
- MIT or Heimdal Kerberos — for Kerberos authentication
- libjpeg — for JPEG support (akallabeth/jpeg8d has been tested)
Building the native libraries
From the repository root, run the build script passing the paths to your NDK and SDK installations:<ANDROID_NDK> and <ANDROID_SDK> with the absolute paths on your machine.
The script will fetch and build:
- OpenSSL
- OpenH264
- libjpeg
- The FreeRDP native libraries
Supported ABIs
The default configuration builds for all four common ABIs:| ABI | Description |
|---|---|
armeabi-v7a | 32-bit ARM |
arm64-v8a | 64-bit ARM |
x86 | 32-bit x86 (emulator) |
x86_64 | 64-bit x86 (emulator) |
scripts/android-build.conf and produces debug builds targeting API level 21 and above.
Release builds
For release binaries (with older Android API support), build the 32-bit and 64-bit architectures separately using the dedicated conf files:Building the APK
- Android Studio
- Gradle (command line)
CMake preload configuration
The repository shipsci/cmake-preloads/config-android.txt with the settings used in CI. Key options:
Updating the JNI bindings
Whenever the FreeRDP C API changes or you need additional functionality exposed to Java:- Edit
client/Android/android_freerdp.cand add the new function to themethodsstruct. - Edit
client/Android/Studio/freeRDPCore/src/main/java/com/freerdp/freerdpcore/services/LibFreeRDP.javato mirror the change.
