linking glut

Hi, I have some problem to link glut to my project (.NET2003). Linker get these errors:

filter_anisotropic error LNK2019: unresolved external symbol ___glutCreateMenuWithExit@8 referenced in function _glutCreateMenu_ATEXIT_HACK@4
filter_anisotropic error LNK2019: unresolved external symbol ___glutCreateWindowWithExit@8 referenced in function _glutCreateWindow_ATEXIT_HACK@4
filter_anisotropic error LNK2019: unresolved external symbol ___glutInitWithExit@12 referenced in function _glutInit_ATEXIT_HACK@8
filter_anisotropic fatal error LNK1120: 3 unresolved externals
filter_anisotropic warning LNK4075: ignoring '/EDITANDCONTINUE' due to '/INCREMENTAL:NO' specification
filter_anisotropic warning LNK4098: defaultlib 'LIBC' conflicts with use of other libs; use /NODEFAULTLIB:library

What am I wronging? Thanks

If you don’t need to register exit functions, do this before including any .h :

#define GLUT_DISABLE_ATEXIT_HACK

or use freeglut or other modern glut ports.

I have the same problem with you .when I link glut to my project (vc++6.0),somethings are wrong:

aindex.obj : error LNK2001: unresolved external symbol ___glutInitWithExit@12
aaindex.obj : error LNK2001: unresolved external symbol ___glutCreateWindowWithExit@8
Debug/aaindex.exe : fatal error LNK1120: 2 unresolved externals
Error executing link.exe.

when I use “#define GLUT_DISABLE_ATEXIT_HACK”,succeed to link.

But I execute the project ,there are still errors: can’t intialize the debugging subsysterm.

I am a beginner,please help me

I have the same problem with you .when I link glut to my project (vc++6.0),somethings are wrong:

aindex.obj : error LNK2001: unresolved external symbol ___glutInitWithExit@12
aaindex.obj : error LNK2001: unresolved external symbol ___glutCreateWindowWithExit@8
Debug/aaindex.exe : fatal error LNK1120: 2 unresolved externals
Error executing link.exe.

when I use “#define GLUT_DISABLE_ATEXIT_HACK”,succeed to link.

But I execute the project ,there are still errors: can’t intialize the debugging subsysterm.

I am a beginner,please help me