----- Original Message ----- 
From: "Arjen Markus" <[email protected]>
To: "Sisyphus" <[email protected]>
Cc: "Alessandro Piras" <[email protected]>; 
<[email protected]>
Sent: Monday, June 21, 2010 8:02 PM
Subject: Re: [Plplot-general] wingcc drivers fails to build on Windows 7 
64bit/VC


> Hi Rob,
>
> On 2010-06-21 11:48, Sisyphus wrote:
>
>>
>> Yep, that's fine.
>> However, I think you should find that both GCLP_HCURSOR and GWLP_USERDATA 
>> *are* defined for 32-bit compilers (and to the same values as their 
>> "P"-less counterparts). It's just that GCL_HCURSOR and GWL_USERDATA are 
>> not defined for Win64.
>>
>
> Hm, I founded my comment on this piece of code (from c:\program 
> files\microsoft sdks\windows\v6.0A\include\winuser.h):
>
>
> #ifdef _WIN64
>
> #undef GCL_MENUNAME
> #undef GCL_HBRBACKGROUND
> #undef GCL_HCURSOR
> #undef GCL_HICON
> #undef GCL_HMODULE
> #undef GCL_WNDPROC
> #undef GCL_HICONSM
>
> #endif /* _WIN64 */
>
> #define GCLP_MENUNAME       (-8)
> #define GCLP_HBRBACKGROUND  (-10)
> #define GCLP_HCURSOR        (-12)
> #define GCLP_HICON          (-14)
> #define GCLP_HMODULE        (-16)
> #define GCLP_WNDPROC        (-24)
> #define GCLP_HICONSM        (-34)
>
> #endif /* !NOWINOFFSETS */
>
> As you can see, it undefines the GCL_* macros before redefining them
> when _WIN64 exists. This may be peculiar to this version and to the
> MicroSoft Visual Studio version it comes with.

If you look closely, you'll see that GCL_CURSOR is indeed undefined for 
Win64 (as you say), but GCLP_HCURSOR is defined for both Win32 and Win64. (I 
initially made the same error when I first looked at the code - but the 
definition of GCLP_HCURSOR is made *outside* of the "#ifdef _WIN64" block.)

> The header file that comes with the GCC compiler does not undefine
> the GCL_* macros. That is the difference.

The ports of gcc available from mingw64.sf.net do undefine those macros for 
_WIN64. But you're right, the gcc ports from mingw.org don't. Instead they 
just define both the "P" and "no P" macros. That may be a mistake ... not 
sure. I'm not aware of it ever causing any problems - and I'm sure that it 
would be addressed if it did ever cause problems.

>> Btw, by chance, I happened to notice that x17c.exe (strip chart demo) 
>> works correctly in the svn version. Whenever I've looked at it before, 
>> the graphs have just super-imposed over each other, resulting in quite a 
>> mess. Now we get one chart after another - which I'm assuming is what's 
>> intended. Nice !
>>
>
> Yes, that was actually a small correction by me and great improvement
> to the demo (the wingcc was lying about it cleaning up the window - it
> said it would but did not).

Yes, definitely an improvement !
I hate it when computers misbehave. Reminds me of a computer called "HAL", 
in a movie called "2001, A Space Odyssey" ......... ;-)

Cheers,
Rob 


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Plplot-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/plplot-general

Reply via email to