| Index: tools/gn/setup.cc
|
| diff --git a/tools/gn/setup.cc b/tools/gn/setup.cc
|
| index 192230d67d99ef60c89b003a970c6c0a19744b35..6f2d2c52ba7e9d9e7a30a26f9f90422cf2aeeed9 100644
|
| --- a/tools/gn/setup.cc
|
| +++ b/tools/gn/setup.cc
|
| @@ -276,7 +276,7 @@ Setup::Setup()
|
| root_build_file_("//BUILD.gn"),
|
| check_public_headers_(false),
|
| dotfile_settings_(&build_settings_, std::string()),
|
| - dotfile_scope_(&dotfile_settings_),
|
| + dotfile_scope_(&dotfile_settings_, {base::Hash("//.gn")}),
|
| default_args_(nullptr),
|
| fill_arguments_(true) {
|
| dotfile_settings_.set_toolchain_label(Label());
|
| @@ -465,7 +465,8 @@ bool Setup::FillArgsFromArgsInputFile() {
|
| return false;
|
| }
|
|
|
| - Scope arg_scope(&dotfile_settings_);
|
| + Scope arg_scope(&dotfile_settings_,
|
| + {base::Hash(args_input_file_->name().value())});
|
| // Set soure dir so relative imports in args work.
|
| SourceDir root_source_dir =
|
| SourceDirForCurrentDirectory(build_settings_.root_path());
|
| @@ -652,6 +653,7 @@ bool Setup::RunConfigFile() {
|
| scheduler_.Log("Got dotfile", FilePathToUTF8(dotfile_name_));
|
|
|
| dotfile_input_file_.reset(new InputFile(SourceFile("//.gn")));
|
| + dotfile_scope_.AddSourceFile(dotfile_input_file_->name());
|
| if (!dotfile_input_file_->Load(dotfile_name_)) {
|
| Err(Location(), "Could not load dotfile.",
|
| "The file \"" + FilePathToUTF8(dotfile_name_) + "\" couldn't be loaded")
|
|
|