<div dir="ltr"><div style>Short answer: <stdarg.h> is not found in that directory.</div><div style><br></div><div style>Long answer: Clang (and the clang libraries) looks for <stdarg.h> and (other compiler-provided headers) in a hardcoded directory relative the the current executable. If your executable is not sitting inside alongside clang inside a clang installation dir or build dir, then the hardcoded path that it looks for won't contain the right headers (if your tool is in such a directory, then I have probably misdiagnosed your issue; I apologize). This has been a pain point for a long time and needs to be fixed, but we have not reached a consensus about the best way to go about it. <<a href="http://clang.llvm.org/docs/FAQ.html">http://clang.llvm.org/docs/FAQ.html</a>> will give you some insight into the issue.</div>
<div><br></div><div><br></div>Dmitri, could you please update/rework <<a href="http://clang.llvm.org/docs/FAQ.html">http://clang.llvm.org/docs/FAQ.html</a>> so that it covers the way that madil90 has posed this question (regardless of whether or not I diagnosed this issue correctly)? Maybe we should have a dedicated question `why does clang not find some headers like "stddef.h" or "stdarg.h"`? The content should be written to fill the use case where we reply to these built-in header questions by just linking to the FAQ and have that give the user a useful understanding of the issue (and what they can do about it, and that they are not alone).<div>
<br></div><div style>-- Sean Silva</div></div>