View Full Version : MSVC++ compiler error - **ABSOLUTE NOVICE**

03-27-2002, 12:37 AM
Im just trying to get to that point where I can compile something that uses the openGL library. As far as I know my environment is setup correctly in the the IDE I use.(MSVC++6.0 on Windows2k Pro)

I have been trying to compile the code from this tutorial: http://www.wazooenterprises.com/tutorials/tutorial1-OGL.html

When it compiles I get these errors:
:\program files\microsoft visual studio\vc98\include\gl\gl.h(1152) : error C2144: syntax error : missing ';' before type 'void'
c:\program files\microsoft visual studio\vc98\include\gl\gl.h(1152) : error C2501: 'WINGDIAPI' : missing storage-class or type specifiers
c:\program files\microsoft visual studio\vc98\include\gl\gl.h(1152) : fatal error C1004: unexpected end of file found

Unless I'm mistaken its telling me theres syntax errors in the header files Im trying to use and that makes no sense to me.

Im lost in the worst way and would appreciate any and all help that any of you might be able to offer me.



Andrea Rossini
03-27-2002, 03:42 AM
maybe add:
#include <windows.h>
before openGL

03-27-2002, 03:46 AM
Hi !

Yes, the "nice" folks at Microsoft has made sure that you must include windows.h before gl.h, so just put #include <windows.h> at the top of the file.