View Full Version : I cant get the ".h" files to work ********NEED HELP********

11-10-2000, 03:44 PM
I am very new to OPENGL I am programing in Visual C++ and I include the following:

#include <gl/gl.h>
#include <gl/glu.h>
#include <windows.h>

void main(){ ; }

and I get back the errors:
(1) error C2144: syntax error : missing ';' before type 'void'
(2)error C2501: 'WINGDIAPI' : missing storage-class or type specifiers
(3) fatal error C1004: unexpected end of file found
and error exe cl.exe

I am pretty sure I linked the .lib's

11-10-2000, 04:05 PM
You need to #include <windows.h> before any other OpenGL files...


11-12-2000, 09:26 AM
just a note, to make it ANSI compliant main should be

int main()
return 1;


Anonymous Coward
11-13-2000, 08:11 AM
If your using C++ your main function should return an integer...