Thursday, March 29, 2007

error C2065: 'INVALID_FILE_ATTRIBUTES' : undeclared identifier Error executing cl.exe.

Cygwin based compilation of opensource components which needs platform sdk 2003 toolkit breaks with the above titled error message.

This failure is basically because of missing macro $define INVALID_FILE_ATTIBUTES ((DWORD) -1)
in winBase.h of platform sdk 2003 installation.

1. Check the "INCLUDE" environmental variable and ensure that the platform sdk is part of this variable.
INCLUDE=C:\Program Files\Microsoft Platfform SDK\Include\.

If platform sdk is part of include variable then look for the macro $define INVALID_FILE_ATTIBUTES ((DWORD) -1) in C:\Program Files\Microsoft Platform SDK\include\winBase.h and if one can see the macro in this file then this is the time to get the latest version of Platform sdk installed.

Above steps will resolve the title issue.

cheers, make world open.

No comments: