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/linux/sysroot.gni") | 5 import("//build/config/linux/sysroot.gni") |
6 | 6 |
7 # Base compiler configuration. | 7 # Base compiler configuration. |
8 config("compiler") { | 8 config("compiler") { |
9 include_dirs = [ "//", root_gen_dir ] | 9 include_dirs = [ "//", root_gen_dir ] |
10 if (is_win) { | 10 if (is_win) { |
(...skipping 14 matching lines...) Expand all Loading... |
25 ] | 25 ] |
26 cflags_cc = [ | 26 cflags_cc = [ |
27 "-fno-exceptions", | 27 "-fno-exceptions", |
28 "-fno-threadsafe-statics", | 28 "-fno-threadsafe-statics", |
29 "-fvisibility-inlines-hidden", | 29 "-fvisibility-inlines-hidden", |
30 ] | 30 ] |
31 ldflags = [ | 31 ldflags = [ |
32 ] | 32 ] |
33 | 33 |
34 # Stack protection. | 34 # Stack protection. |
35 # TODO(brettw) why do we have different values for all of these cases? | |
36 if (is_mac) { | 35 if (is_mac) { |
37 cflags += "-fstack-protector-all" | 36 cflags += "-fstack-protector-all" |
38 } else if (is_chromeos) { | |
39 cflags += "-fstack-protector-strong" | |
40 } else if (is_linux) { | 37 } else if (is_linux) { |
41 cflags += [ "-fstack-protector", "--param=ssp-buffer-size=4" ] | 38 cflags += [ "-fstack-protector", "--param=ssp-buffer-size=4" ] |
42 } | 39 } |
43 | 40 |
44 if (is_mac) { | 41 if (is_mac) { |
45 # Mac-specific compiler flags setup. | 42 # Mac-specific compiler flags setup. |
46 # ---------------------------------- | 43 # ---------------------------------- |
47 | 44 |
48 # These flags are shared between the C compiler and linker. | 45 # These flags are shared between the C compiler and linker. |
49 common_mac_flags = [ | 46 common_mac_flags = [ |
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 } else { | 412 } else { |
416 cflags = [ "-g1" ] | 413 cflags = [ "-g1" ] |
417 } | 414 } |
418 } | 415 } |
419 | 416 |
420 config("no_symbols") { | 417 config("no_symbols") { |
421 if (!is_win) { | 418 if (!is_win) { |
422 cflags = [ "-g0" ] | 419 cflags = [ "-g0" ] |
423 } | 420 } |
424 } | 421 } |
OLD | NEW |