Index: build/config/compiler/BUILD.gn |
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn |
index 1eaa390c156bd963f2066087645085a3fde47560..c4d61e2281a7662b4a3ca17b8fe92dac7d15469b 100644 |
--- a/build/config/compiler/BUILD.gn |
+++ b/build/config/compiler/BUILD.gn |
@@ -534,13 +534,6 @@ config("compiler_cpu_abi") { |
"-march=$arm_arch", |
"-mfloat-abi=$arm_float_abi", |
] |
- if (arm_use_thumb) { |
- cflags += [ "-mthumb" ] |
- if (is_android && !is_clang) { |
- # Clang doesn't support this option. |
- cflags += [ "-mthumb-interwork" ] |
- } |
- } |
} |
if (arm_tune != "") { |
cflags += [ "-mtune=$arm_tune" ] |
@@ -765,6 +758,17 @@ config("compiler_arm_fpu") { |
} |
} |
+config("compiler_arm_thumb") { |
+ if (current_cpu == "arm" && arm_use_thumb && is_posix && |
+ !(is_mac || is_ios || is_nacl)) { |
+ cflags = [ "-mthumb" ] |
+ if (is_android && !is_clang) { |
+ # Clang doesn't support this option. |
+ cflags += [ "-mthumb-interwork" ] |
+ } |
+ } |
+} |
+ |
# runtime_library ------------------------------------------------------------- |
# |
# Sets the runtime library and associated options. |