From 4718b6eaa8052f0d3cd0a07b40dffd77a0df0e16 Mon Sep 17 00:00:00 2001 From: Alexander David Frick Date: Tue, 2 Aug 2022 13:41:08 -0500 Subject: [PATCH] Update BUILD.gn --- arm/config/compiler/BUILD.gn | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/arm/config/compiler/BUILD.gn b/arm/config/compiler/BUILD.gn index 3aff1925..746fb893 100644 --- a/arm/config/compiler/BUILD.gn +++ b/arm/config/compiler/BUILD.gn @@ -709,6 +709,16 @@ config("compiler") { ldflags += [ "-fwhole-program-vtables" ] } } + + if (is_win && target_cpu == "arm64") { + cflags += [ "-O3", "-Wno-error", "-Wno-unreachable-code", "-Wno-unused-command-line-argument", ] + ldflags += [ "-Wno-unused-command-line-argument", ] + } + + if (is_linux && target_cpu == "arm64") { + cflags += [ "-O3", "-Wno-error", "-Wno-unreachable-code", "-Wno-unused-command-line-argument", ] + ldflags += [ "-Wl,-O3", "-Wno-unused-command-line-argument", ] + } # This flag causes LTO to create an .ARM.attributes section with the correct # architecture. This is necessary because LLD will refuse to link a program