projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
55abd2b
)
[clang-scan-deps] Add -M to work around -MT issue after r371918
author
Fangrui Song
<maskray@google.com>
Sat, 14 Sep 2019 07:25:27 +0000
(07:25 +0000)
committer
Fangrui Song
<maskray@google.com>
Sat, 14 Sep 2019 07:25:27 +0000
(07:25 +0000)
gcc will complain if -MT is used but neither -M nor -MM is specified:
> cc1: error: to generate dependencies you must specify either -M or -MM
r371918 changed our behavior to match GCC, but apparently
clang-scan-deps is not happy.
llvm-svn: 371920
clang/tools/clang-scan-deps/ClangScanDeps.cpp
patch
|
blob
|
history
diff --git
a/clang/tools/clang-scan-deps/ClangScanDeps.cpp
b/clang/tools/clang-scan-deps/ClangScanDeps.cpp
index
4bd61fb
..
6e8d9a9
100644
(file)
--- a/
clang/tools/clang-scan-deps/ClangScanDeps.cpp
+++ b/
clang/tools/clang-scan-deps/ClangScanDeps.cpp
@@
-242,6
+242,7
@@
int main(int argc, const char **argv) {
AdjustedArgs.push_back("-o");
AdjustedArgs.push_back("/dev/null");
if (!HasMT && !HasMQ) {
+ AdjustedArgs.push_back("-M");
AdjustedArgs.push_back("-MT");
// We're interested in source dependencies of an object file.
if (!HasMD) {