Chromium Code Reviews| Index: runtime/BUILD.gn |
| diff --git a/runtime/BUILD.gn b/runtime/BUILD.gn |
| index 6e987c46f0718069d52bb1a95f3f7a11b6c2d6a8..a4bc67c9160720942a2702fcf6e5066562fcbba9 100644 |
| --- a/runtime/BUILD.gn |
| +++ b/runtime/BUILD.gn |
| @@ -12,6 +12,10 @@ declare_args() { |
| # while themselves doing a Debug build. |
| dart_debug = false |
| + # Product mode drops many features (e.g. debugger, profiler, etc) in order to |
| + # shrink download size and decrease power usage. |
|
Ivan Posva
2016/04/12 21:51:34
"decrease memory and cpu usage"
Power might or mi
|
| + dart_product = false |
| + |
| # Explicitly set the target architecture in case of precompilation. Leaving |
| # this unspecified results in automatic target architecture detection. |
| # Available options are: arm, arm64, mips, x64 and ia32 |
| @@ -50,6 +54,15 @@ config("dart_config") { |
| defines += ["NDEBUG"] |
| } |
| + if (dart_product) { |
| + if (dart_debug) { |
| + print("Debug and product mode are mutually exclusive.") |
| + } |
| + assert(!dart_debug) |
| + defines += ["PRODUCT"] |
| + } |
| + |
| + |
| if (is_ios || is_mac) { |
| defines += ["DART_PRECOMPILER"] |
| } |
| @@ -113,6 +126,14 @@ config("dart_config_no_precompiler") { |
| defines += ["NDEBUG"] |
| } |
| + if (dart_product) { |
| + if (dart_debug) { |
| + print("Debug and product mode are mutually exclusive.") |
| + } |
| + assert(!dart_debug) |
| + defines += ["PRODUCT"] |
| + } |
| + |
| cflags = [ |
| "-Werror", |
| "-Wall", |