Compile a Win32 console Socket program using XP SP2 Platform SDK

I'm using VC2005 express edtion with Platform SDK to compile a socket program. When I include the <Winsock2.h> in my program, the compiler start generating warnings about 'macro redefinition like below:

c:\program files\microsoft platform sdk for windows xp sp2\include\specstrings.h(341) : warning C4005: '__checkReturn' : macro redefinition
c:\program files\microsoft visual studio 8\vc\include\sal.h(703) : see previous definition of '__checkReturn'

How to solve this problem beside using #pragma directive to turn of the warning?

[585 byte] By [AaronTan] at [2008-3-5]
# 1
Hi,
Why do not you change your PSDK from XP2 PSDK to Windows Server 2003 PSDK first. Somebody on the Internet once told me to install 2003 PSDK. I cannot remember exactly who told me so. Check the 2003 PSDK page carefully before replacing XP PSDK with 2003 PSDK. Can anybody please correct me if I am wrong?
Hope this helps.
TakashiToyota at 2007-9-8 > top of Msdn Tech,Visual Studio Express Editions,Visual C++ 2005 Express Edition...
# 2
Thanks Takashi! I don't have the problem again with Win2003 PSDK.
Smile
AaronTan at 2007-9-8 > top of Msdn Tech,Visual Studio Express Editions,Visual C++ 2005 Express Edition...
# 3

Takashi,

I did try Windows Server 2003 PSDK as part of msvc 2005 SP1.

Recompiled my apps and got problem delivering to the clients. Some dll wont register itself under power user account (WinXP):

"80070005 unable to register". On some machines (WinXP) got "load lib failed: 14001 unable to load" error message.


A quick search leads to security settings for this folder:

"C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\MachineKeys"

I'm not sure if it is a right investigation. Could somebody help to clarify what was wrong with server PSDK?

Did reinstall back to platform Windows XP sdk and everything went smooth as before.

Any comments are very welcome.

gok

gokh at 2007-9-8 > top of Msdn Tech,Visual Studio Express Editions,Visual C++ 2005 Express Edition...