develooper Front page | perl.perl5.porters | Postings from November 2003

Re: [PATCH] Re: MinGW-3.1.0-1 _CRTIMP definition preempting win32.h's

Thread Previous | Thread Next
From:
Abe Timmerman
Date:
November 2, 2003 10:26
Subject:
Re: [PATCH] Re: MinGW-3.1.0-1 _CRTIMP definition preempting win32.h's
Message ID:
200311021924.48650.abe@ztreet.demon.nl
Op een wisselvallige herfstdag (Sunday 02 November 2003 15:51), schreef Abe 
Timmerman:

> Op een wisselvallige herfstdag (Sunday 02 November 2003 15:09), schreef
> Rafael
>
> Garcia-Suarez:
> > So a simple patch like this one should solve the problem. Does it look
> > good ? (sorry, I can't test it, no MinGW here)
[snip]
> > End of Patch.
>
> applied on 21466 (blead), that seems to make it build (tests still running)
>
> As Jan D. notices it is rather loud (the redefine warnings).

I've now done Jan's suggestion, which looks better (checked with blead && 
5.6.2 for both MinGW2 and MinGW3):

--- win32/win32.h.orig  2003-05-11 18:51:19.000000000 +0200
+++ win32/win32.h       2003-11-02 16:14:53.000000000 +0100
@@ -465,6 +465,9 @@
 #ifdef PERL_CORE

 /* C doesn't like repeat struct definitions */
+#if defined(__MINGW32__) && (__MINGW32_MAJOR_VERSION>=3)
+#undef _CRTIMP
+#endif
 #ifndef _CRTIMP
 #define _CRTIMP __declspec(dllimport)
 #endif



Good luck,

Abe
-- 
"Jarkko Hietaniemi" is actually the code name for a whole team of Finnish
super-programmers, capable of working continuously 25 hours a day without
tripping each other up, and running solely only on intravenous caffeine.
                                      -- Nicholas Clark on p5p @ 2002-03-04


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About