Game Development Community

Having a problem with the compiling glu2d3d

by David Stewart · in Torque Game Engine · 10/18/2005 (4:15 pm) · 5 replies

Hello,
this is not really a Torque problem, but it came up when i was trying to build glu2d3d from TGE 1.4rc2

I am using VC++ 2005 Express Beta 2.
The problem is my lack of C++ knowledge and in the Platform SDK.

There are 5 errors, 2 are about line 222 and the other 3 are about line 5940.
I'm pretty sure that the errors on line 5940 will go away once the problem on line 222 is fixed.

Now, I don't know if the issue is actually in the Platform SDK or if it is because of a naming conflict with the Torque source.

Can anyone see the problem and explain it?
If it really does seem to be an issue with the Platform SDK, I will report it to Microsoft.

Thanks.



The Errors:

G:\programs\Microsoft Platform SDK\include\winnt.h(222) : error C2146: syntax error : missing ';' before identifier 'PVOID64'
G:\programs\Microsoft Platform SDK\include\winnt.h(222) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
G:\programs\Microsoft Platform SDK\include\winnt.h(5940) : error C2146: syntax error : missing ';' before identifier 'Buffer'
G:\programs\Microsoft Platform SDK\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
G:\programs\Microsoft Platform SDK\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

The lines of code:
typedef void *PVOID;
typedef void * POINTER_64 PVOID64;   [b]<- this is line 222[/b]
...
typedef union _FILE_SEGMENT_ELEMENT {
    PVOID64 Buffer;     [b]<-- This is line 5940[/b]
    ULONGLONG Alignment;
}FILE_SEGMENT_ELEMENT, *PFILE_SEGMENT_ELEMENT;

#1
10/18/2005 (4:35 pm)
Looking on the microsoft site, it seems that there may be an issue with the order of the include files. It may have an issue with the DX sdk.
going to try rearranging the includes.
#2
10/18/2005 (4:44 pm)
This was from the T2D.Net docs and may have relevance:

you also have to modify line 222 of winnt.h to:
typedef void * POINTER_64;
typedef void * PVOID64;

ie split the line into two defines.
#3
10/18/2005 (4:45 pm)
Thanks, J. E.
Going to try now.

...

Update: It worked. Thanks, J. E.
#4
10/18/2005 (6:14 pm)
Ugh.

Now the Torque Tool Libs complain about the ; in line: typedef void * POINTER_64;
#5
05/13/2007 (1:10 pm)
This is years ago now, was there a resolution cos I'm having the same issue and can't find anything to fix it.