Author loewis
Recipients RubyTuesdayDONO, Seppo.Yli-Olli, alexis, cmcqueen1975, jonforums, loewis, merwok, pje, rpetrov, rubenvb, santoso.wijaya, schmir, tarek
Date 2012-07-10.10:11:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1341915078.62.0.283231291833.issue12641@psf.upfronthosting.co.za>
In-reply-to
Content
I just installed the cygwin gcc4 package; this gives me gcc 4.5.3. In this version, -mno-cygwin is still recognized, and gives this error message:

gcc: The -mno-cygwin flag has been removed; use a mingw-targeted cross-compiler.

So it seems that removing the -mno-cygwin flag is definitely incorrect, as it will result in a cygwin binary.

I then installed the mingw-gcc-core package, which gave me the utility  i686-pc-mingw32-gcc, which indeed is able to create a (nearly) correct binary.

So I think we should check whether i686-pc-mingw32-gcc exists in the path, and if so, use it (without a -mno-cygwin flag). If it doesn't exist, we should continue to use gcc -mno-cygwin.

My remaining concern with i686-pc-mingw32-gcc is that it still links with msvcrt.dll in addition to linking with msvcrXY.dll; this is incorrect.

There is another concern that this applies to 32-bit mode only; in 64-bit mode,  i686-w64-mingw32-gcc should be used. However, this is issue 4709.
History
Date User Action Args
2012-07-10 10:11:18loewissetrecipients: + loewis, pje, schmir, tarek, merwok, rpetrov, cmcqueen1975, rubenvb, santoso.wijaya, alexis, Seppo.Yli-Olli, jonforums, RubyTuesdayDONO
2012-07-10 10:11:18loewissetmessageid: <1341915078.62.0.283231291833.issue12641@psf.upfronthosting.co.za>
2012-07-10 10:11:18loewislinkissue12641 messages
2012-07-10 10:11:16loewiscreate