OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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/ui.gni") | 5 import("//build/config/ui.gni") |
6 import("//third_party/WebKit/public/features.gni") | 6 import("//third_party/WebKit/public/features.gni") |
7 | 7 |
8 if (is_android) { | 8 if (is_android) { |
9 import("//build/config/android/config.gni") | 9 import("//build/config/android/config.gni") |
10 } | 10 } |
11 if (current_cpu == "arm") { | 11 if (current_cpu == "arm") { |
12 import("//build/config/arm.gni") | 12 import("//build/config/arm.gni") |
13 } else { | 13 } else { |
14 # TODO(brettw) remove this once && early-out is checked in. | 14 # TODO(brettw) remove this once && early-out is checked in. |
15 arm_version = 0 | 15 arm_version = 0 |
16 } | 16 } |
17 | 17 |
18 declare_args() { | 18 declare_args() { |
19 # Set to true to enable the clang plugin that checks the usage of the Blink | 19 # Set to true to enable the clang plugin that checks the usage of the Blink |
20 # garbage-collection infrastructure during compilation. | 20 # garbage-collection infrastructure during compilation. |
21 blink_gc_plugin = true | 21 blink_gc_plugin = true |
| 22 |
| 23 # If true, force blink asserts to be off in a release build. When false, |
| 24 # blink asserts in release build may be controlled by DCHECK_ALWAYS_ON. |
| 25 blink_asserts_off_in_release = false |
22 } | 26 } |
23 | 27 |
24 # Whether Android ARM or x86 build uses OpenMAX DL FFT. Currently only | 28 # Whether Android ARM or x86 build uses OpenMAX DL FFT. Currently only |
25 # supported on Android ARMv7+, ia32 or x64 without webview. When enabled, this | 29 # supported on Android ARMv7+, ia32 or x64 without webview. When enabled, this |
26 # will also enable WebAudio support on Android ARM, ia32 and x64. Default is | 30 # will also enable WebAudio support on Android ARM, ia32 and x64. Default is |
27 # enabled. Whether WebAudio is actually available depends on runtime settings | 31 # enabled. Whether WebAudio is actually available depends on runtime settings |
28 # and flags. | 32 # and flags. |
29 use_openmax_dl_fft = | 33 use_openmax_dl_fft = |
30 is_android && | 34 is_android && |
31 (current_cpu == "x86" || current_cpu == "x64" || | 35 (current_cpu == "x86" || current_cpu == "x64" || |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 "ENABLE_WEB_AUDIO=1", | 87 "ENABLE_WEB_AUDIO=1", |
84 ] | 88 ] |
85 } | 89 } |
86 | 90 |
87 if (use_default_render_theme) { | 91 if (use_default_render_theme) { |
88 feature_defines_list += [ "WTF_USE_DEFAULT_RENDER_THEME=1" ] | 92 feature_defines_list += [ "WTF_USE_DEFAULT_RENDER_THEME=1" ] |
89 } | 93 } |
90 if (enable_oilpan) { | 94 if (enable_oilpan) { |
91 feature_defines_list += [ "ENABLE_OILPAN=1" ] | 95 feature_defines_list += [ "ENABLE_OILPAN=1" ] |
92 } | 96 } |
| 97 if (blink_asserts_off_in_release && !is_debug) { |
| 98 feature_defines_list += [ "ENABLE_ASSERT=0" ] |
| 99 } |
93 | 100 |
94 # feature_defines_string ------------------------------------------------------- | 101 # feature_defines_string ------------------------------------------------------- |
95 | 102 |
96 # Convert the list to a space-separated string for passing to scripts. | 103 # Convert the list to a space-separated string for passing to scripts. |
97 # This would be the equivalent of passing '<(feature_defines)' in GYP. | 104 # This would be the equivalent of passing '<(feature_defines)' in GYP. |
98 feature_defines_string = | 105 feature_defines_string = |
99 exec_script("build/gn_list_to_space_separated_string.py", | 106 exec_script("build/gn_list_to_space_separated_string.py", |
100 feature_defines_list, | 107 feature_defines_list, |
101 "trim string") | 108 "trim string") |
OLD | NEW |