OLD | NEW |
---|---|
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/android/config.gni") | 5 import("//build/config/android/config.gni") |
6 import("//build/config/chrome_build.gni") | 6 import("//build/config/chrome_build.gni") |
7 import("//build/config/compiler/compiler.gni") | 7 import("//build/config/compiler/compiler.gni") |
8 import("//build/config/nacl/config.gni") | 8 import("//build/config/nacl/config.gni") |
9 import("//build/toolchain/ccache.gni") | 9 import("//build/toolchain/ccache.gni") |
10 | 10 |
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
443 "-Wa,-mips64r6", | 443 "-Wa,-mips64r6", |
444 ] | 444 ] |
445 ldflags += [ "-mips64r6" ] | 445 ldflags += [ "-mips64r6" ] |
446 } else if (mips_arch_variant == "r2") { | 446 } else if (mips_arch_variant == "r2") { |
447 cflags += [ | 447 cflags += [ |
448 "-mips64r2", | 448 "-mips64r2", |
449 "-Wa,-mips64r2", | 449 "-Wa,-mips64r2", |
450 ] | 450 ] |
451 ldflags += [ "-mips64r2" ] | 451 ldflags += [ "-mips64r2" ] |
452 } | 452 } |
453 } else if (current_cpu == "pnacl" && is_nacl_nonsfi) { | |
454 if (target_cpu == "x86" || target_cpu == "x64") { | |
455 cflags += [ | |
456 "-arch", | |
457 "x86-32-nonsfi", | |
458 "--pnacl-bias=x86-32-nonsfi", | |
459 "--target=i686-unknown-nacl", | |
460 ] | |
461 ldflags += [ | |
462 "-arch", | |
463 "x86-32-nonsfi", | |
464 "--target=i686-unknown-nacl", | |
465 ] | |
466 } else if (target_cpu == "arm") { | |
467 cflags += [ | |
468 "-arch", | |
469 "arm-nonsfi", | |
470 "--pnacl-bias=arm-nonsfi", | |
471 ] | |
472 ldflags += [ | |
473 "-arch", | |
474 "arm-nonsfi", | |
475 ] | |
476 } | |
453 } | 477 } |
454 } | 478 } |
455 | 479 |
456 asmflags = cflags | 480 asmflags = cflags |
457 } | 481 } |
458 | 482 |
459 # This provides options to tweak code generation that are necessary | 483 # This provides options to tweak code generation that are necessary |
460 # for particular Chromium code or for working around particular | 484 # for particular Chromium code or for working around particular |
461 # compiler bugs (or the combination of the two). | 485 # compiler bugs (or the combination of the two). |
462 config("compiler_codegen") { | 486 config("compiler_codegen") { |
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
751 if (!is_nacl) { | 775 if (!is_nacl) { |
752 # Flags NaCl (Clang 3.7) does not recognize. | 776 # Flags NaCl (Clang 3.7) does not recognize. |
753 cflags += [ | 777 cflags += [ |
754 # TODO(thakis): Enable this, crbug.com/507717 | 778 # TODO(thakis): Enable this, crbug.com/507717 |
755 "-Wno-shift-negative-value", | 779 "-Wno-shift-negative-value", |
756 | 780 |
757 # TODO(thakis): Consider enabling this? | 781 # TODO(thakis): Consider enabling this? |
758 "-Wno-bitfield-width", | 782 "-Wno-bitfield-width", |
759 ] | 783 ] |
760 } | 784 } |
785 | |
786 if (is_nacl_nonsfi) { | |
brettw
2015/10/23 09:38:13
This block seems very strange to me. Why are we di
Petr Hosek
2015/10/23 17:53:07
I originally copied the configuration from Gyp but
| |
787 cflags += [ | |
788 # Disables | |
789 "-Wno-c++11-extensions", | |
790 "-Wno-char-subscripts", | |
791 "-Wno-extra-semi", | |
792 "-Wno-unnamed-type-template-args", | |
793 "-Wno-unused-private-field", | |
794 "-Wno-unused-function", | |
795 "-Wno-sign-compare", | |
796 ] | |
797 } | |
761 } | 798 } |
762 } | 799 } |
763 | 800 |
764 # chromium_code --------------------------------------------------------------- | 801 # chromium_code --------------------------------------------------------------- |
765 # | 802 # |
766 # Toggles between higher and lower warnings for code that is (or isn't) | 803 # Toggles between higher and lower warnings for code that is (or isn't) |
767 # part of Chromium. | 804 # part of Chromium. |
768 | 805 |
769 config("chromium_code") { | 806 config("chromium_code") { |
770 if (is_win) { | 807 if (is_win) { |
(...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1183 if (symbol_level == 0) { | 1220 if (symbol_level == 0) { |
1184 configs = [ ":no_symbols" ] | 1221 configs = [ ":no_symbols" ] |
1185 } else if (symbol_level == 1) { | 1222 } else if (symbol_level == 1) { |
1186 configs = [ ":minimal_symbols" ] | 1223 configs = [ ":minimal_symbols" ] |
1187 } else if (symbol_level == 2) { | 1224 } else if (symbol_level == 2) { |
1188 configs = [ ":symbols" ] | 1225 configs = [ ":symbols" ] |
1189 } else { | 1226 } else { |
1190 assert(false) | 1227 assert(false) |
1191 } | 1228 } |
1192 } | 1229 } |
OLD | NEW |