diff options
author | Brad King <brad.king@kitware.com> | 2022-08-22 14:58:46 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-08-22 19:29:43 (GMT) |
commit | 52c95540b722926ba833ead05a575189bdabf84e (patch) | |
tree | b620d3dfeaabb69d61a9e3c2413a0d73692d6968 /Source/cmTargetSourcesCommand.cxx | |
parent | 0d64c3abd13a0b14f1a14b7717dbac8988d12256 (diff) | |
download | CMake-52c95540b722926ba833ead05a575189bdabf84e.zip CMake-52c95540b722926ba833ead05a575189bdabf84e.tar.gz CMake-52c95540b722926ba833ead05a575189bdabf84e.tar.bz2 |
target_*: Fix cross-directory call backtraces
Record the call-site backtrace, not the current backtrace of the
target's directory.
Fixes: #23873
Diffstat (limited to 'Source/cmTargetSourcesCommand.cxx')
-rw-r--r-- | Source/cmTargetSourcesCommand.cxx | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/Source/cmTargetSourcesCommand.cxx b/Source/cmTargetSourcesCommand.cxx index e2b0213..53e25b5 100644 --- a/Source/cmTargetSourcesCommand.cxx +++ b/Source/cmTargetSourcesCommand.cxx @@ -79,7 +79,8 @@ private: { tgt->AppendProperty("SOURCES", this->Join(this->ConvertToAbsoluteContent( - tgt, content, IsInterface::No, CheckCMP0076::Yes))); + tgt, content, IsInterface::No, CheckCMP0076::Yes)), + this->Makefile->GetBacktrace()); return true; // Successfully handled. } @@ -324,11 +325,13 @@ bool TargetSourcesImpl::HandleOneFileSet( cmStrCat("$<BUILD_INTERFACE:", dir, ">"); if (cmFileSetVisibilityIsForSelf(visibility)) { this->Target->AppendProperty("INCLUDE_DIRECTORIES", - interfaceDirectoriesGenex); + interfaceDirectoriesGenex, + this->Makefile->GetBacktrace()); } if (cmFileSetVisibilityIsForInterface(visibility)) { this->Target->AppendProperty("INTERFACE_INCLUDE_DIRECTORIES", - interfaceDirectoriesGenex); + interfaceDirectoriesGenex, + this->Makefile->GetBacktrace()); } } } |