[cfe-users] Standard headers cannot be found when compiling with Clang

Hans Wennborg via cfe-users cfe-users at lists.llvm.org
Fri Jan 15 08:56:32 PST 2016


On Fri, Jan 15, 2016 at 7:06 AM, Qiuping Yi via cfe-users
<cfe-users at lists.llvm.org> wrote:
> Hello All,
>
> I am a beginner of clang. I installed clang 3.6 with llvm 3.6, but I found
> my clang cannot work as expected.
> For the next simple program test.c:
>
> #include <stdio.h>
> int main() {return 0;}
>
> $ clang -c test.c
>
> I got the next information:
>
> fatal error: 'stdio.h' file not found
> #include <stdio.h>
>              ^
> 1 error generated.
>
> what's wrong? I found other standard headers are also cannot be found.
> Any suggestion is OK. Thank you in advance.

What operating system are you using?

What's the output of "clang -v -c test.c"?

>From where did you install clang?



More information about the cfe-users mailing list