diff options
author | Ben Boeckel <ben.boeckel@kitware.com> | 2023-11-20 14:15:46 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2023-11-21 14:41:59 (GMT) |
commit | 77a7edb73fcfee88c4998bd8e4d72aaddc5524e5 (patch) | |
tree | 7685988f591208d9249a36386ceb091cdf4420b4 /Modules/FindOpenSP.cmake | |
parent | 079bf537fd869e5dc098f15dacfc999790ff6a13 (diff) | |
download | CMake-77a7edb73fcfee88c4998bd8e4d72aaddc5524e5.zip CMake-77a7edb73fcfee88c4998bd8e4d72aaddc5524e5.tar.gz CMake-77a7edb73fcfee88c4998bd8e4d72aaddc5524e5.tar.bz2 |
Clang-CXX: copy into the dyndep output on success
When `clang-scan-deps` fails to scan (e.g., bad source syntax, junk
flags, etc.), the redirection unconditionally updates the file. If this
fails, the `.ddi` file timestamp is updated. If the state is then
reverted (e.g., the command line returns to the state of the last
successful build), the updated file is not useful, but `ninja` does not
rerun because:
- the command hash matches the last successful run
- the output file is newer than its inputs
However, since the `.ddi` file has been updated with bogus contents from
a failed scan, collation fails as the `rules` array is empty (or
incomplete from a batch scan).
If `clang-scan-deps` were properly aware of its output file, it could
use this to not write the file if any inner scan fails. Requested in
https://github.com/llvm/llvm-project/issues/72875.
See: https://github.com/llvm/llvm-project/issues/72875
Fixes: #25429
Diffstat (limited to 'Modules/FindOpenSP.cmake')
0 files changed, 0 insertions, 0 deletions