gn should warn on multiple toolchains with the same root_out_dir |
|||
Issue descriptionIn bug 660857 , two different gn toolchains ended up with the same name. gn wrote both to the same directory, clobbering the files of one with the files of the other. ninja's -w dupbuild did warn and, on some bots, error about this, which allowed us to find this. It'd be nicer if gn could check if two toolchains it writes out have the same name at gn time though.
,
Nov 6 2016
https://codereview.chromium.org/2483713003/
,
Nov 8 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/eab6e2d58dc3b71e094ff58d822980ca3473caf8 commit eab6e2d58dc3b71e094ff58d822980ca3473caf8 Author: thakis <thakis@chromium.org> Date: Tue Nov 08 01:44:32 2016 gn: Diag on distinct toolchains with the same name. Previously, toolchains with the same name used to silently write to the same output directory and clobber each others generated .ninja files. After this patch, this still happens, but gn writes an error message while writing the final build.ninja file. Example output: ERROR at //build/toolchain/mac2/BUILD.gn:51:3: Duplicate toolchain. toolchain(target_name) { ^----------------------- Two or more toolchains write to the same directory: //out/gn1/clang_x64/ This can be fixed by making sure that distinct toolchains have distinct names. See //build/toolchain/mac3/BUILD.gn:51:3: Previous toolchain. toolchain(target_name) { ^----------------------- Depends on https://codereview.chromium.org/2485523002/ BUG= 661054 Review-Url: https://codereview.chromium.org/2483713003 Cr-Commit-Position: refs/heads/master@{#430473} [modify] https://crrev.com/eab6e2d58dc3b71e094ff58d822980ca3473caf8/tools/gn/ninja_build_writer.cc [modify] https://crrev.com/eab6e2d58dc3b71e094ff58d822980ca3473caf8/tools/gn/ninja_build_writer.h
,
Nov 8 2016
|
|||
►
Sign in to add a comment |
|||
Comment 1 by dpranke@chromium.org
, Nov 1 2016Components: Build
Labels: OS-All
Status: Available (was: Untriaged)
Summary: gn should warn on multiple toolchains with the same root_out_dir (was: gn should warn on multiple toolchains with the same name)