-
-
Notifications
You must be signed in to change notification settings - Fork 35
Build for Android
Radu Marias edited this page Aug 4, 2024
·
2 revisions
Install these
sudo pacman -S musl clang llvm
yay -S android-sdk android-sdk-build-tools
yay -S android-sdk android-ndk
in ~/.cargo/config.toml
:
[target.aarch64-linux-android]
ar = "/home/gnome/Android/Sdk/ndk/NDK/arm64/bin/aarch64-linux-android-ar"
linker = "/home/gnome/Android/Sdk/ndk/NDK/arm64/bin/aarch64-linux-android-clang"
[target.armv7-linux-androideabi]
ar = "/home/gnome/Android/Sdk/ndk/NDK/arm/bin/arm-linux-androideabi-ar"
linker = "/home/gnome/Android/Sdk/ndk/NDK/arm/bin/arm-linux-androideabi-clang"
[target.i686-linux-android]
ar = "/home/gnome/Android/Sdk/ndk/NDK/x86/bin/i686-linux-android-ar"
linker = "/home/gnome/Android/Sdk/ndk/NDK/x86/bin/i686-linux-android-clang"
[target.x86_64-pc-windows-gnu]
linker = "x86_64-w64-mingw32-gcc"
[target.i686-pc-windows-gnu]
linker = "i686-w64-mingw32-gcc"
[target.x86_64-apple-darwin]
ar = "x86_64-apple-darwin23.6-ar"
linker = "x86_64-apple-darwin23.6-clang"
rustflags = ["-C", "link-arg=-mmacosx-version-min=10.7"]
[target.aarch64-apple-darwin]
ar = "aarch64-apple-darwin23.6-ar"
linker = "aarch64-apple-darwin23.6-clang"
rustflags = ["-C", "link-arg=-mmacosx-version-min=11.0"]
TODO:
- how to create images in
NDK
folder