Public Group

# Microsoft Platform SDK Compile Errors

This topic is 4285 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hey folks! Im building a small 2D tile based games engine using DirectX 9, to develop a few simple games such as tic tac toe using sprites (Im using a cut-down version of Jim Adams' engine from Programming Role Playing Games in DirectX). I've a small test programme to test the engine, but on compilation I receieve the following errors: c:\program files\microsoft platform sdk for windows server 2003 r2\include\winnt.h(222) : error C2146: syntax error : missing ';' before identifier 'PVOID64' c:\program files\microsoft platform sdk for windows server 2003 r2\include\winnt.h(222) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft platform sdk for windows server 2003 r2\include\winnt.h(5940) : error C2146: syntax error : missing ';' before identifier 'Buffer' c:\program files\microsoft platform sdk for windows server 2003 r2\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft platform sdk for windows server 2003 r2\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int Im not so sure if this is due to an incorrect option selected somewhere, or something else. If anyone needs to take a peek at my code, I'll be more than happy to submit it (though it is rather lengthy). Thankyou in advance for any help, it is really appreciated.

##### Share on other sites
What compiler are you using?

##### Share on other sites
Im using Visual C++ 2005 Express edition at the moment.

##### Share on other sites
What include file directories do you have set up in VS2005?

Look in Tools > Options > Projects and Solutions > VC++ Directories.

##### Share on other sites
Besides the three default includes, I have:

C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include
C:\DX90SDK\Include

##### Share on other sites
Still pulling my hair out with this one.. I prefer it when the compiler moans at my code in all honesty! :P

##### Share on other sites
OK, the problem seems to be that Winnt.h is including basetsd.h, but the version of basetsd.h that comes with DirectX is being used rather than that in the Platform SDK.

One fix would be to change the line
#include <basetsd.h>
in winnt.h to point explicitly at basetsd.h in Platform SDK\Include.

##### Share on other sites
Aha okay, thankyou very much!

In winnt.h I see the line #include <basetsd.h>. How do I make it explicitly point to the microsoft SDK version?

I guess i need to brush up on my C++ :(

##### Share on other sites
Either overwrite the one you want with the one you don't, or make sure "C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include" is listed before "C:\DX90SDK\Include" in the include folders list.

##### Share on other sites
That worked perfectly, and its all compiling.

Thankyou for all your help, Id be useless without this forum!

1. 1
Rutin
19
2. 2
3. 3
4. 4
5. 5
frob
12

• 15
• 13
• 9
• 12
• 10
• ### Forum Statistics

• Total Topics
631442
• Total Posts
3000102
×

## Important Information

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!