I see. Thank you!
I have download "clang+llvm-3.1-i386-mingw32-EXPERIMENTAL.tar.bz2" and I merge this with MinGW32's folders include "bin" "include" "lib" "libexec" "mingw32" and so on.
Now, I can use "clang.exe main.c -o main.exe" to print "Hellow World" and without -triple=i386-pc-mingw32.
But I will still try to build clang with VS2008 this night, and test -triple=i386-pc-mingw32 and ld.exe tomorrow.
If this works, I can use VS2008 to hack Clang and get round Micro$oft Link.exe.
I think it is better than hacking Clang with MinGW32, as there is no good IDE for MinGW32 AFAIN.
======= 2012-08-29 15:11:49 ÄúÔÚÀ´ÐÅÖÐÐ´µÀ£º=======
You just pass this to clang.exe which acts as a driver. Everything
from there should happen automagically
You should be able to achieve what
you want by passing -triple=i386-pc-mingw32 to the driver.
You meam I pass -triple=i386-pc-mingw32 to the Clang, and Clang will auto use ld.exe to link object files?
Or I must launch ld.exe manually?
= = = = = = = = = = = = = = = = = = = =