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

Side by Side Diff: build/toolchain/mac/BUILD.gn

Issue 2664063004: Add GN assert to prevent GOMA from being used with static analyzer. (Closed)
Patch Set: Mac changes Created 3 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
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | 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) 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 # TODO(brettw) Use "gcc_toolchain.gni" like the Linux toolchains. This requires 5 # TODO(brettw) Use "gcc_toolchain.gni" like the Linux toolchains. This requires
6 # some enhancements since the commands on Mac are slightly different than on 6 # some enhancements since the commands on Mac are slightly different than on
7 # Linux. 7 # Linux.
8 8
9 import("../goma.gni") 9 import("../goma.gni")
10 import("//build/config/clang/clang.gni") 10 import("//build/config/clang/clang.gni")
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 compiler_prefix = "$goma_dir/gomacc " 117 compiler_prefix = "$goma_dir/gomacc "
118 } else if (toolchain_cc_wrapper != "") { 118 } else if (toolchain_cc_wrapper != "") {
119 compiler_prefix = toolchain_cc_wrapper + " " 119 compiler_prefix = toolchain_cc_wrapper + " "
120 } else { 120 } else {
121 compiler_prefix = "" 121 compiler_prefix = ""
122 } 122 }
123 123
124 cc = compiler_prefix + _cc 124 cc = compiler_prefix + _cc
125 cxx = compiler_prefix + _cxx 125 cxx = compiler_prefix + _cxx
126 126
127 if (use_clang_static_analyzer && !toolchain_uses_goma) { 127 if (use_clang_static_analyzer) {
128 # Static analysis isn't supported under GOMA. See crbug.com/687245
129 # for progress on this issue.
130 assert(!use_goma, "'use_clang_static_analyzer' cannot be used with GOMA.")
131
128 # Call "ccc-analyzer" or "c++-analyzer" instead of directly calling Clang. 132 # Call "ccc-analyzer" or "c++-analyzer" instead of directly calling Clang.
129 # |wrapper_tool| sets the environment variables which are read by the 133 # |wrapper_tool| sets the environment variables which are read by the
130 # analyzer tools. 134 # analyzer tools.
131 analyzer_wrapper = 135 analyzer_wrapper =
132 rebase_path("//build/toolchain/clang_static_analyzer_wrapper.py", 136 rebase_path("//build/toolchain/clang_static_analyzer_wrapper.py",
133 root_build_dir) 137 root_build_dir)
134 cc = analyzer_wrapper + " --clang-cc-path=${cc} --analyzer=" + 138 cc = analyzer_wrapper + " --clang-cc-path=${cc} --analyzer=" +
135 rebase_path("//third_party/scan-build/src/libexec/ccc-analyzer", 139 rebase_path("//third_party/scan-build/src/libexec/ccc-analyzer",
136 root_build_dir) 140 root_build_dir)
137 cxx = analyzer_wrapper + " --clang-cxx-path=${cxx} --analyzer=" + 141 cxx = analyzer_wrapper + " --clang-cxx-path=${cxx} --analyzer=" +
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
516 } 520 }
517 } 521 }
518 522
519 mac_toolchain("ios_clang_x64") { 523 mac_toolchain("ios_clang_x64") {
520 toolchain_args = { 524 toolchain_args = {
521 current_cpu = "x64" 525 current_cpu = "x64"
522 current_os = "ios" 526 current_os = "ios"
523 } 527 }
524 } 528 }
525 } 529 }
OLDNEW
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698