Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(56)

Side by Side Diff: runtime/BUILD.gn

Issue 905753003: Adds dart_debug parameter to GN build. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 # Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 # for details. All rights reserved. Use of this source code is governed by a 2 # for details. All rights reserved. Use of this source code is governed by a
3 # BSD-style license that can be found in the LICENSE file. 3 # BSD-style license that can be found in the LICENSE file.
4 4
5 # TODO(zra): These build arguments should likely be moved to a gni file that is
6 # included in BUILD.gn files that care about the values of the flags. For now,
7 # since the GN build only happens as part of a Mojo build there is no need for
8 # the indirection.
9 declare_args() {
10 # Instead of using is_debug, we introduce a different flag for specifying a
11 # Debug build of Dart so that clients can still use a Release build of Dart
12 # while themselves doing a Debug build.
13 dart_debug = false
14 }
15
5 config("dart_config") { 16 config("dart_config") {
6 defines = [] 17 defines = []
7 if (is_debug) { 18 if (dart_debug) {
8 defines += ["DEBUG"] 19 defines += ["DEBUG"]
9 } else { 20 } else {
10 defines += ["NDEBUG"] 21 defines += ["NDEBUG"]
11 } 22 }
12 23
13 cflags = [ 24 cflags = [
14 "-Werror", 25 "-Werror",
15 "-Wall", 26 "-Wall",
16 "-Wextra", # Also known as -W. 27 "-Wextra", # Also known as -W.
17 "-Wno-unused-parameter", 28 "-Wno-unused-parameter",
18 "-Wnon-virtual-dtor", 29 "-Wnon-virtual-dtor",
19 "-Wvla", 30 "-Wvla",
20 "-Wno-conversion-null", 31 "-Wno-conversion-null",
21 "-Woverloaded-virtual", 32 "-Woverloaded-virtual",
22 "-g3", 33 "-g3",
23 "-ggdb3", 34 "-ggdb3",
24 "-fno-rtti", 35 "-fno-rtti",
25 "-fno-exceptions", 36 "-fno-exceptions",
26 ] 37 ]
38
39 if (dart_debug) {
40 cflags += [
41 "-O1",
42 ]
43 } else {
44 cflags += [
45 "-O3",
46 ]
47 }
27 } 48 }
28 49
29 50
30 static_library("libdart") { 51 static_library("libdart") {
31 configs += [":dart_config"] 52 configs += [":dart_config"]
32 deps = [ 53 deps = [
33 "vm:libdart_lib", 54 "vm:libdart_lib",
34 "vm:libdart_vm", 55 "vm:libdart_vm",
35 "third_party/jscre:libjscre", 56 "third_party/jscre:libjscre",
36 "third_party/double-conversion/src:libdouble_conversion", 57 "third_party/double-conversion/src:libdouble_conversion",
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 args = [ 96 args = [
76 "--quiet", 97 "--quiet",
77 "--output", rebase_path(output, root_build_dir), 98 "--output", rebase_path(output, root_build_dir),
78 "--input", rebase_path("vm/version_in.cc", root_build_dir), 99 "--input", rebase_path("vm/version_in.cc", root_build_dir),
79 "--ignore_svn_revision", 100 "--ignore_svn_revision",
80 ] 101 ]
81 } 102 }
82 103
83 104
84 executable("libdart_dependency_helper") { 105 executable("libdart_dependency_helper") {
106 configs += [":dart_config"]
85 deps = [ 107 deps = [
86 "vm:libdart_lib_withcore", 108 "vm:libdart_lib_withcore",
87 "vm:libdart_lib", 109 "vm:libdart_lib",
88 "vm:libdart_vm", 110 "vm:libdart_vm",
89 "vm:libdart_platform", 111 "vm:libdart_platform",
90 "third_party/jscre:libjscre", 112 "third_party/jscre:libjscre",
91 "third_party/double-conversion/src:libdouble_conversion", 113 "third_party/double-conversion/src:libdouble_conversion",
92 ] 114 ]
93 sources = [ 115 sources = [
94 "vm/libdart_dependency_helper.cc", 116 "vm/libdart_dependency_helper.cc",
95 ] 117 ]
96 } 118 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698