Merge pull request #5 from dart-lang/zanderso-patch-2
Pass a -march flag for arm64 clang build
diff --git a/BUILD.gn b/BUILD.gn
index d9f5160..a9b4a50 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -42,13 +42,14 @@
defines = []
sources = []
include_dirs = [ "src/include" ]
+ asmflags = []
if ((current_cpu == "arm" || current_cpu == "arm64") && is_android && is_clang) {
# Disable the integrated assembler and use the one shipped with the NDK.
import("//build/config/android/config.gni")
rebased_android_toolchain_root =
rebase_path(android_toolchain_root, root_build_dir)
- asmflags = [
+ asmflags += [
"-fno-integrated-as",
"-B${rebased_android_toolchain_root}/bin",
]
@@ -79,6 +80,7 @@
sources += crypto_sources_linux_arm
} else if (current_cpu == "arm64" && (is_linux || is_android)) {
sources += crypto_sources_linux_aarch64
+ asmflags += [ "-march=armv8-a+crypto" ]
} else {
public_configs = [ ":no_asm_config" ]
}