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 # ============================================================================= | 5 # ============================================================================= |
6 # WHAT IS THIS FILE? | 6 # WHAT IS THIS FILE? |
7 # ============================================================================= | 7 # ============================================================================= |
8 # | 8 # |
9 # This is the master GN build configuration. This file is loaded after the | 9 # This is the master GN build configuration. This file is loaded after the |
10 # build args (args.gn) for the build directory and after the toplevel ".gn" | 10 # build args (args.gn) for the build directory and after the toplevel ".gn" |
(...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
510 ] | 510 ] |
511 } | 511 } |
512 | 512 |
513 # Debug/release-related defines. | 513 # Debug/release-related defines. |
514 if (is_debug) { | 514 if (is_debug) { |
515 default_compiler_configs += [ "//build/config:debug" ] | 515 default_compiler_configs += [ "//build/config:debug" ] |
516 } else { | 516 } else { |
517 default_compiler_configs += [ "//build/config:release" ] | 517 default_compiler_configs += [ "//build/config:release" ] |
518 } | 518 } |
519 | 519 |
| 520 # Lastly, add a setting to give toolchains an extra chance to override |
| 521 # flags as needed. |
| 522 default_compiler_configs += [ "//build/config/compiler:extra_flags" ] |
| 523 |
520 # Static libraries and source sets use only the compiler ones. | 524 # Static libraries and source sets use only the compiler ones. |
521 set_defaults("static_library") { | 525 set_defaults("static_library") { |
522 configs = default_compiler_configs | 526 configs = default_compiler_configs |
523 } | 527 } |
524 set_defaults("source_set") { | 528 set_defaults("source_set") { |
525 configs = default_compiler_configs | 529 configs = default_compiler_configs |
526 } | 530 } |
527 | 531 |
528 # Compute the set of configs common to all linked targets (shared libraries, | 532 # Compute the set of configs common to all linked targets (shared libraries, |
529 # loadable modules, executables) to avoid duplication below. | 533 # loadable modules, executables) to avoid duplication below. |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
639 set_defaults("component") { | 643 set_defaults("component") { |
640 if (is_component_build) { | 644 if (is_component_build) { |
641 configs = default_shared_library_configs | 645 configs = default_shared_library_configs |
642 if (is_android) { | 646 if (is_android) { |
643 configs -= [ "//build/config/android:hide_native_jni_exports" ] | 647 configs -= [ "//build/config/android:hide_native_jni_exports" ] |
644 } | 648 } |
645 } else { | 649 } else { |
646 configs = default_compiler_configs | 650 configs = default_compiler_configs |
647 } | 651 } |
648 } | 652 } |
OLD | NEW |