-
Notifications
You must be signed in to change notification settings - Fork 120
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Android CI: Enable KVM, Caching and AArch64 (#296)
* CI: Bump Android API version and add arm64-v8a target * CI: Avoid using date +%N * CI: Enable KVM and caching of AVD * CI: Change shebang in android driver
- Loading branch information
Showing
3 changed files
with
81 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/bin/sh | ||
|
||
export ANDROID_NDK_HOME=~/Library/Android/sdk/ndk/24.0.8215888 | ||
export TOOLCHAIN=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/darwin-x86_64 | ||
export CCPREFIX=$TOOLCHAIN/bin/aarch64-linux-android24 | ||
export CC="$CCPREFIX-clang" | ||
export CXX="$CCPREFIX-clang++" | ||
export OBJC="$CCPREFIX-clang" | ||
export OBJCXX="$CCPREFIX-clang++" | ||
export AS="$CCPREFIX-clang" | ||
export LD="$TOOLCHAIN/bin/ld.lld" | ||
export AR="$TOOLCHAIN/bin/llvm-ar" | ||
export RANLIB="$TOOLCHAIN/bin/llvm-ranlib" | ||
export STRIP="$TOOLCHAIN/bin/llvm-strip" | ||
export NM="$TOOLCHAIN/bin/llvm-nm" | ||
export OBJDUMP="$TOOLCHAIN/bin/llvm-objdump" | ||
export LDFLAGS="-fuse-ld=lld" | ||
export LIBS="-lc++_shared" | ||
|
||
cmake -B build \ | ||
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK_HOME/build/cmake/android.toolchain.cmake \ | ||
-DANDROID_ABI=arm64-v8a \ | ||
-DANDROID_NDK=$ANDROID_NDK_HOME \ | ||
-DANDROID_STL=c++_shared \ | ||
-DCMAKE_FIND_USE_CMAKE_PATH=false \ | ||
-DCMAKE_C_COMPILER=$CC \ | ||
-DCMAKE_CXX_COMPILER=$CXX \ | ||
-DCMAKE_ASM_COMPILER=$AS \ | ||
-DCMAKE_BUILD_TYPE=Debug \ | ||
-DTESTS=ON \ | ||
-DANDROID_PLATFORM=android-24 \ | ||
-G Ninja |