[cfe-dev] Use MinGW ld.exe with Clang in Windows

fiveight fiveight at tom.com
Wed Aug 29 00:48:49 PDT 2012


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 :)
>
>On Wed, Aug 29, 2012 at 8:44 AM, fiveight <fiveight at tom.com> wrote:
>>>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?
>

= = = = = = = = = = = = = = = = = = = =
			

        致
礼!
 
				 
        fiveight
        fiveight at tom.com
          2012-08-29





More information about the cfe-dev mailing list