Redbook Samples + Visual Studio 2008

I downloaded the first Redbbok sample “aaindex” into Visual Studio 2008 and go the following message

1>------ Build started: Project: aaindex, Configuration: Debug Win32 ------
1>Compiling…
1>aaindex.cpp
1>c:\program files\microsoft visual studio 9.0\vc\include\stdlib.h(371) : error C2381: ‘exit’ : redefinition; __declspec(noreturn) differs
1> c:\program files\microsoft visual studio 9.0\vc\include\gl\glut.h(146) : see declaration of ‘exit’
1>c:\program files\microsoft visual studio 9.0\vc\include\stdlib.h(371) : warning C4985: ‘exit’: attributes not present on previous declaration.
1> c:\program files\microsoft visual studio 9.0\vc\include\gl\glut.h(146) : see declaration of ‘exit’
1>c:\documents and settings\alan.wilhite\desktop\opengl misc\aaindex\aaindex\aaindex.cpp(129) : error C3861: ‘exit’: identifier not found
1>Build log was saved at “file://c:\Documents and Settings\alan.wilhite\Desktop\Opengl Misc\aaindex\aaindex\Debug\BuildLog.htm”
1>aaindex - 2 error(s), 1 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

Can anyone get me started?

Thanks for any help

I think you problem is the same as what is discussed here:

http://stackoverflow.com/questions/14264/using-glut-with-visual-c-express-edition

basically try putting:

#define GLUT_DISABLE_ATEXIT_HACK

before you include glut.

I hope that helps.