Hi cfe-dev,
I downloaded the pre-built clang from llvm official download page. And find that it’s built with Visual Studio.
But locally I haven’t install Visual Studio yet.
My question is: How can clang work with my local pre-installed MInGW gcc-toolchain?
For eg:
If the design files include or something like header files, it will error out with following error message:
C:>“C:\Program Files\LLVM\bin\clang++.exe” main.cpp
main.cpp:1:10: fatal error: ‘cstdio’ file not found
#include
^
1 error generated.
So is there any option, like ‘-gcc-toolchain’ option on Linux platform to specify a header file path, to let the clang (build with Visual Studio) to find the header files AUTOMATICALLY, not though ‘-I’ option?
I tried ‘-gcc-toolchain’ on Windows platform, it cannot work, and put following warning message:
C:>“C:\Program Files\LLVM\bin\clang++.exe” main.cpp dut.cpp -gcc-toolchain “C:\mingw64”
clang++.exe: warning: argument unused during compilation: ‘–gcc-toolchain=C:\msys64\mingw64’
Thanks a lot!
Fangqing