diff options
author | Liam <[email protected]> | 2023-03-16 11:56:51 -0400 |
---|---|---|
committer | bunnei <[email protected]> | 2023-06-03 00:05:43 -0700 |
commit | 616cf70a801ccf7c2312118d163185a8d341e517 (patch) | |
tree | 063170927625dfda9151bf20a5f2d44da6fc51b7 /CMakeLists.txt | |
parent | 515f3deea18bd367b0faf847e8a9b215238fc312 (diff) | |
download | yuzu-android-616cf70a801ccf7c2312118d163185a8d341e517.tar.gz yuzu-android-616cf70a801ccf7c2312118d163185a8d341e517.zip |
build: only enable adrenotools on arm64
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 2d25cc3a9..1771b063c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -106,12 +106,20 @@ endif() if (YUZU_USE_BUNDLED_VCPKG) if (ANDROID) - set(VCPKG_TARGET_TRIPLET "arm64-android") set(ENV{ANDROID_NDK_HOME} "${ANDROID_NDK}") - # this is to avoid CMake using the host pkg-config to find the host - # libraries when building for Android targets - set(PKG_CONFIG_EXECUTABLE "aarch64-none-linux-android-pkg-config" CACHE FILEPATH "" FORCE) list(APPEND VCPKG_MANIFEST_FEATURES "android") + + if (CMAKE_ANDROID_ARCH_ABI STREQUAL "arm64-v8a") + set(VCPKG_TARGET_TRIPLET "arm64-android") + # this is to avoid CMake using the host pkg-config to find the host + # libraries when building for Android targets + set(PKG_CONFIG_EXECUTABLE "aarch64-none-linux-android-pkg-config" CACHE FILEPATH "" FORCE) + elseif (CMAKE_ANDROID_ARCH_ABI STREQUAL "x86_64") + set(VCPKG_TARGET_TRIPLET "x64-android") + set(PKG_CONFIG_EXECUTABLE "x86_64-none-linux-android-pkg-config" CACHE FILEPATH "" FORCE) + else() + message(FATAL_ERROR "Unsupported Android architecture ${CMAKE_ANDROID_ARCH_ABI}") + endif() endif() if (YUZU_TESTS) |