[llvm-bugs] [Bug 45800] New: clang -MMD only records last source file's dependencies
via llvm-bugs
llvm-bugs at lists.llvm.org
Mon May 4 17:31:37 PDT 2020
https://bugs.llvm.org/show_bug.cgi?id=45800
Bug ID: 45800
Summary: clang -MMD only records last source file's
dependencies
Product: clang
Version: unspecified
Hardware: Macintosh
OS: MacOS X
Status: NEW
Severity: normal
Priority: P
Component: Driver
Assignee: unassignedclangbugs at nondot.org
Reporter: kbob at jogger-egg.com
CC: llvm-bugs at lists.llvm.org, neeilans at live.com,
richard-llvm at metafoo.co.uk
Created attachment 23442
--> https://bugs.llvm.org/attachment.cgi?id=23442&action=edit
sources shown in the description
When compiling two or more source files into an executable (not 'cc -c') and
creating a make dependency file with -MMD, clang only records the last source
file's dependencies.
Transcript, observe that both.d does not mention one.c.
sim$ ls
one.c two.c
sim$ head *
==> one.c <==
extern void two(void);
int main()
{
two();
return 0;
}
==> two.c <==
void two() {}
sim$ clang -MMD one.c two.c -o both
sim$ cat both.d
both: two.c
sim$ clang --version
Apple clang version 11.0.0 (clang-1100.0.33.17)
Target: x86_64-apple-darwin18.7.0
Thread model: posix
InstalledDir:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
sim$
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200505/dc82427f/attachment.html>
More information about the llvm-bugs
mailing list