Commit 77d631e9 authored by Andrew Grieve's avatar Andrew Grieve Committed by Commit Bot

Android: Minor simplification to conditionals in abi.gni

No behaviour change

Change-Id: I457a35b215c545a5049b67739607aa5b331ca301
Reviewed-on: https://chromium-review.googlesource.com/c/1455115
Commit-Queue: Christopher Grant <cjgrant@chromium.org>
Auto-Submit: Andrew Grieve <agrieve@chromium.org>
Reviewed-by: default avatarChristopher Grant <cjgrant@chromium.org>
Cr-Commit-Position: refs/heads/master@{#629595}
parent a5cfc369
...@@ -44,37 +44,23 @@ if (current_cpu == "x86") { ...@@ -44,37 +44,23 @@ if (current_cpu == "x86") {
android_app_abi = "mips" android_app_abi = "mips"
} else if (current_cpu == "x64") { } else if (current_cpu == "x64") {
android_app_abi = "x86_64" android_app_abi = "x86_64"
android_secondary_abi_cpu = "x86"
android_app_secondary_abi = "x86"
} else if (current_cpu == "arm64") { } else if (current_cpu == "arm64") {
android_app_abi = "arm64-v8a" android_app_abi = "arm64-v8a"
android_secondary_abi_cpu = "arm"
android_app_secondary_abi = "armeabi-v7a"
} else if (current_cpu == "mips64el") { } else if (current_cpu == "mips64el") {
android_app_abi = "mips64" android_app_abi = "mips64"
android_secondary_abi_cpu = "mipsel"
android_app_secondary_abi = "mips"
} else { } else {
assert(false, "Unknown Android ABI: " + current_cpu) assert(false, "Unknown Android ABI: " + current_cpu)
} }
if (target_cpu == "arm64" || target_cpu == "x64" || target_cpu == "mips64el") { android_64bit_target_cpu = defined(android_app_secondary_abi)
android_64bit_target_cpu = true
} else if (target_cpu == "arm" || target_cpu == "x86" ||
target_cpu == "mipsel") {
android_64bit_target_cpu = false
} else {
assert(false, "Unknown target CPU: $target_cpu")
}
# Intentionally do not define android_app_secondary_abi_cpu and
# android_app_secondary_abi for 32-bit target_cpu, since they are not used.
if (target_cpu == "arm64") {
android_secondary_abi_cpu = "arm"
android_app_secondary_abi = "armeabi-v7a"
} else if (target_cpu == "x64") {
android_secondary_abi_cpu = "x86"
android_app_secondary_abi = "x86"
} else if (target_cpu == "mips64el") {
android_secondary_abi_cpu = "mipsel"
android_app_secondary_abi = "mips"
}
if (defined(android_secondary_abi_cpu)) { if (android_64bit_target_cpu) {
android_secondary_abi_toolchain = android_secondary_abi_toolchain =
"//build/toolchain/android:android_clang_${android_secondary_abi_cpu}" "//build/toolchain/android:android_clang_${android_secondary_abi_cpu}"
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment