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

Side by Side Diff: build/config/compiler/BUILD.gn

Issue 2281963002: Use -fdiagnostics-absolute-paths in Win-Clang builds (Closed)
Patch Set: Created 4 years, 3 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 | « 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) 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 import("//build/config/android/config.gni") 5 import("//build/config/android/config.gni")
6 import("//build/config/chrome_build.gni") 6 import("//build/config/chrome_build.gni")
7 import("//build/config/compiler/compiler.gni") 7 import("//build/config/compiler/compiler.gni")
8 import("//build/config/nacl/config.gni") 8 import("//build/config/nacl/config.gni")
9 import("//build/toolchain/cc_wrapper.gni") 9 import("//build/toolchain/cc_wrapper.gni")
10 import("//build/toolchain/toolchain.gni") 10 import("//build/toolchain/toolchain.gni")
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 if (linux_use_bundled_binutils) { 365 if (linux_use_bundled_binutils) {
366 cflags += [ "-B$binutils_path" ] 366 cflags += [ "-B$binutils_path" ]
367 } 367 }
368 368
369 # Clang-specific compiler flags setup. 369 # Clang-specific compiler flags setup.
370 # ------------------------------------ 370 # ------------------------------------
371 if (is_clang) { 371 if (is_clang) {
372 cflags += [ "-fcolor-diagnostics" ] 372 cflags += [ "-fcolor-diagnostics" ]
373 } 373 }
374 374
375 # Windows devs want absolute paths in diagnostics (crbug.com/636109).
Nico 2016/08/26 17:06:24 Maybe you can expand this a bit based on discussio
hans 2016/08/26 20:50:06 Done.
376 # TODO(hans) Remove llvm_force_head_revision check in next clang roll.
377 if (is_clang && is_win && llvm_force_head_revision) {
Nico 2016/08/26 16:13:01 Should we do this on all platforms? Seems a bit ar
hans 2016/08/26 16:21:43 I agree it might seem a bit odd to do it on only o
scottmg 2016/08/26 16:58:34 Yeah, I would agree with keeping it Windows-only.
378 cflags += [ "-fdiagnostics-absolute-paths" ]
379 }
380
375 # Makes builds independent of absolute file path. 381 # Makes builds independent of absolute file path.
376 # clang-cl (used if is_win) doesn't expose this flag. 382 # clang-cl (used if is_win) doesn't expose this flag.
377 # Currently disabled for nacl since its toolchain lacks this flag (too old). 383 # Currently disabled for nacl since its toolchain lacks this flag (too old).
378 # TODO(zforman): Once nacl's toolchain is updated, remove check. 384 # TODO(zforman): Once nacl's toolchain is updated, remove check.
379 if (is_clang && is_linux) { 385 if (is_clang && is_linux) {
380 absolute_path = rebase_path("//.") 386 absolute_path = rebase_path("//.")
381 cflags += [ "-fdebug-prefix-map=$absolute_path=." ] 387 cflags += [ "-fdebug-prefix-map=$absolute_path=." ]
382 } 388 }
383 389
384 # C++11 compiler flags setup. 390 # C++11 compiler flags setup.
(...skipping 1199 matching lines...) Expand 10 before | Expand all | Expand 10 after
1584 1590
1585 if (is_ios || is_mac) { 1591 if (is_ios || is_mac) {
1586 # On Mac and iOS, this enables support for ARC (automatic ref-counting). 1592 # On Mac and iOS, this enables support for ARC (automatic ref-counting).
1587 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html. 1593 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html.
1588 config("enable_arc") { 1594 config("enable_arc") {
1589 common_flags = [ "-fobjc-arc" ] 1595 common_flags = [ "-fobjc-arc" ]
1590 cflags_objc = common_flags 1596 cflags_objc = common_flags
1591 cflags_objcc = common_flags 1597 cflags_objcc = common_flags
1592 } 1598 }
1593 } 1599 }
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