system include not correct

Hi ,

I compiled the llvm and clang from github by Mingw64, and installed it.

When I tried to build a sample cpp source file, the clang++ can’t find the standard library includes file,

I googled a lot, but can’t resolve my problem.

I will appreciate your help very much. Thanks

C:\Work\workspace_ecl\my_temp\testing\src>clang++ -v testing.cpp

clang version 8.0.0 (https://github.com/llvm-project/clang.git 58281c244d412d258

80a9b0dfebc6fb88ce55c50) (https://github.com/llvm-project/llvm.git b1493403a4118

390aeeb929e3d4ac7489dd0d167)

Target: x86_64-w64-windows-gnu

Thread model: posix

InstalledDir: C:\Program Files (x86)\LLVM\bin

“C:\Program Files (x86)\LLVM\bin\clang++.exe” -cc1 -triple x86_64-w64-windo

ws-gnu -emit-obj -mrelax-all -disable-free -main-file-name testing.cpp -mrelocat

ion-model pic -pic-level 2 -mthread-model posix -fmath-errno -masm-verbose -mcon

structor-aliases -munwind-tables -target-cpu x86-64 -dwarf-column-info -debugger

-tuning=gdb -momit-leaf-frame-pointer -v -resource-dir "C:\Program Files (x86)\

\LLVM\lib\clang\8.0.0" -internal-isystem "C:\Program Files (x86)\LLVM\x86_

64-w64-mingw32\include\c++" -internal-isystem "C:\Program Files (x86)\LLVM\

x86_64-w64-mingw32\include\c++\x86_64-w64-mingw32" -internal-isystem "C:\Pro

gram Files (x86)\LLVM\x86_64-w64-mingw32\include\c++\backward" -internal-is

ystem “C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\include\c++\” -inter

nal-isystem "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\include\c++\\

x86_64-w64-mingw32" -internal-isystem "C:\Program Files (x86)\LLVM\x86_64-w64

-mingw32\include\c++\\backward" -internal-isystem "C:\Program Files (x86)\

LLVM\include\c++\" -internal-isystem "C:\Program Files (x86)\LLVM\include\

\c++\\x86_64-w64-mingw32" -internal-isystem "C:\Program Files (x86)\LLVM\in

clude\c++\\backward" -internal-isystem “include\c++” -internal-isystem "incl

ude\c++\x86_64-w64-mingw32" -internal-isystem “include\c++\backward” -intern

al-isystem “C:\Program Files (x86)\LLVM\lib\clang\8.0.0\include” -internal

-isystem "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32/sys-root/mingw/inclu

de" -internal-isystem "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\includ

e" -internal-isystem “C:\Program Files (x86)\LLVM\include” -fdeprecated-macro

-fdebug-compilation-dir “C:\Work\workspace_ecl\my_temp\testing\src” -ferro

r-limit 19 -fmessage-length 80 -fno-use-cxa-atexit -fobjc-runtime=gcc -fcxx-exce

ptions -fexceptions -fseh-exceptions -fdiagnostics-show-option -fcolor-diagnosti

cs -o “C:\Users\ZTan1\AppData\Local\Temp\testing-7835fe.o” -x c++ testing.

cpp -faddrsig

clang -cc1 version 8.0.0 based upon LLVM 8.0.0svn default target x86_64-w64-wind

ows-gnu

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude\c++"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude\c++\x86_64-w64-mingw32"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude\c++\backward"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude\c++"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude\c++\x86_64-w64-mingw32"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude\c++\backward"

ignoring nonexistent directory “C:\Program Files (x86)\LLVM\include\c++”

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\include\c++\x86_64-

w64-mingw32"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\include\c++\backwar

d"

ignoring nonexistent directory “include\c++”

ignoring nonexistent directory “include\c++\x86_64-w64-mingw32”

ignoring nonexistent directory “include\c++\backward”

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32/s

ys-root/mingw/include"

ignoring nonexistent directory "C:\Program Files (x86)\LLVM\x86_64-w64-mingw32\i

nclude"

#include “…” search starts here:

#include <…> search starts here:

C:\Program Files (x86)\LLVM\lib\clang\8.0.0\include

C:\Program Files (x86)\LLVM\include

End of search list.

testing.cpp:9:10: fatal error: ‘iostream’ file not found

#include

^~~~~~~~~~

1 error generated.

Best Regards,

Jenrry

Shanghai

+(86) 13371868669