omdown
08-06-2010, 02:44 PM
Platform: VS 2005
OS: Windows 7 64-bit
Trying to compile a very simple test app using GLEW, I'm getting unresolved externals trying. I've simplified it to the following:
#include <GL/glew.h>
#include <GL/glut.h>
void render() {
glClear( GL_COLOR_BUFFER_BIT );
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glutSwapBuffers();
}
int main ( int argc, char **argv ) {
glutInit( &argc, argv );
glutInitWindowSize( 500, 500 );
glutInitWindowPosition( 100, 100 );
glutCreateWindow( "GLEW Compile Test" );
glutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE);
glutDisplayFunc(render);
glewInit();
glutMainLoop();
return 0;
}
Compiling this linking against glut32.lib and glew32.lib gives me:
1>Linking...
1>main.obj : error LNK2019: unresolved external symbol __imp__glewInit referenced in function _main
I ran a dumpbin.exe /EXPORTS of glew32.lib and glewInit is there, so I have no idea why it's having problems. I tell you, I've NEVER had as much problem compiling code as I have since I started working in Visual Studio. I can't track down what could possibly be causing this.
Any ideas?
OS: Windows 7 64-bit
Trying to compile a very simple test app using GLEW, I'm getting unresolved externals trying. I've simplified it to the following:
#include <GL/glew.h>
#include <GL/glut.h>
void render() {
glClear( GL_COLOR_BUFFER_BIT );
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glutSwapBuffers();
}
int main ( int argc, char **argv ) {
glutInit( &argc, argv );
glutInitWindowSize( 500, 500 );
glutInitWindowPosition( 100, 100 );
glutCreateWindow( "GLEW Compile Test" );
glutInitDisplayMode(GLUT_RGBA | GLUT_DOUBLE);
glutDisplayFunc(render);
glewInit();
glutMainLoop();
return 0;
}
Compiling this linking against glut32.lib and glew32.lib gives me:
1>Linking...
1>main.obj : error LNK2019: unresolved external symbol __imp__glewInit referenced in function _main
I ran a dumpbin.exe /EXPORTS of glew32.lib and glewInit is there, so I have no idea why it's having problems. I tell you, I've NEVER had as much problem compiling code as I have since I started working in Visual Studio. I can't track down what could possibly be causing this.
Any ideas?