1
votes

Sorry, but where can I find mingw32 with the same directories structure as Clang assumes ?

I downloaded 32bit version from here http://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win32/Personal%20Builds/mingw-builds/

Also another one from here http://sourceforge.net/projects/mingwbuilds/files/host-windows/releases/4.8.1/32-bit/threads-posix/dwarf/

but all of the not the same as what clang searches for when I run :

clang++ -v main.cpp
the resut:
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.0/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.0/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.0/include/c++/backw
ard"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.1/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.1/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.1/include/c++/backw
ard"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.2/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.2/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.2/include/c++/backw
ard"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.3/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.3/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.7.3/include/c++/backw
ard"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.0/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.0/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.0/include/c++/backw
ard"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.1/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.1/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.1/include/c++/backw
ard"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.2/include/c++"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.2/include/c++/mingw
32"
ignoring nonexistent directory "c:/MinGW/lib/gcc/mingw32/4.8.2/include/c++/backw
ard"
ignoring nonexistent directory "/usr/include/c++/4.4"
ignoring nonexistent directory "/usr/local/include"
ignoring nonexistent directory "C:\LLVM\bin\..\lib\clang\3.6.0\../../../i686-w64
-mingw32/include"
ignoring nonexistent directory "C:\LLVM\bin\..\lib\clang\3.6.0\../../../x86_64-w
64-mingw32/include"
ignoring nonexistent directory "/mingw/include"
ignoring nonexistent directory "c:/mingw/include"
ignoring nonexistent directory "/usr/include"
#include "..." search starts here:
#include  search starts here:
 C:\LLVM\bin\..\lib\clang\3.6.0\include
 C:\LLVM\bin\..\lib\clang\3.6.0\../../../include
End of search list.
main.cpp:1:10: fatal error: 'iostream' file not found
#include 
2
This article works for me :) Installing Clang 3.5 for Windows Regards.Ahmed T. Ali

2 Answers

2
votes

Have you tried use mingw-get installation tools to install corresponding compiler and headers? In my knowledge, mingw provide GNU tools in Windows command lines and Cygwin provide them in a *nix like command lines (usually bash). Apparently your error is due to clang can not find headers so I wonder if you have them installed correctly or not :)

0
votes

Let me counter your question with another: why on earth would you want such a beast? See, in general it is a very bad idea to mix system components from disparate compiler tool chains. If you want to use clang, then use clang system components, and keep MinGW system components well out of its way; conversely, if you want to use MinGW, use its system components, and keep clang's out of its way.

By all means install both, but keep them both physically and logically separated; never attempt to use system components belonging to one in conjunction with the other. If you adhere to this dictum, then the file system structure for MinGW will be correct for MinGW, and that for clang will be correct for clang; you have no need to concern yourself that they may differ, one from the other.