Visual C++ 6 Compile Error

C

Connell Gauld

Hi,
I am quite new to C++ programming and I have been experimenting with
OpenGL and GLUT. When using one of the sample files for loading models,
on compilation I get the following error.

Example1.obj : error LNK2001: unresolved external symbol "void __cdecl
glmDelete(struct GLMmodel *)" (?glmDelete@@YAXPAUGLMmodel@@@Z)

Now, is this caused by an error in my code, or is it caused by an error
in the sample file I'm including?

Thanks
Connell
 
J

John Harrison

Connell Gauld said:
Hi,
I am quite new to C++ programming and I have been experimenting with
OpenGL and GLUT. When using one of the sample files for loading models,
on compilation I get the following error.

Example1.obj : error LNK2001: unresolved external symbol "void __cdecl
glmDelete(struct GLMmodel *)" (?glmDelete@@YAXPAUGLMmodel@@@Z)

Now, is this caused by an error in my code, or is it caused by an error
in the sample file I'm including?

Well gosh, in the COMPLETE ABSENCE of any posted code it is impossible to
tell.

What this error means is that somewhere in your code (or the sample code)
you are calling the function glmDelete, but nowhere in the your code (or the
sample code) is a definition for that function provided.

I would say that the most likely reason for that is that you are building
your program in the wrong way, perhaps you are not including some file in
your build that you should be. But that is a guess for what should be
obvious reasons.

john
 
C

Connell Gauld

John said:
Well gosh, in the COMPLETE ABSENCE of any posted code it is impossible to
tell.

What this error means is that somewhere in your code (or the sample code)
you are calling the function glmDelete, but nowhere in the your code (or the
sample code) is a definition for that function provided.

I would say that the most likely reason for that is that you are building
your program in the wrong way, perhaps you are not including some file in
your build that you should be. But that is a guess for what should be
obvious reasons.

john
Thanks, I'm sorry for the lack of code but I have been having similar
problems elsewhere and I was looking for a kinda generic answer, which I
got.
Thanks again,
Connell
 
J

JKop

Connell Gauld posted:
Hi,
I am quite new to C++ programming and I have been experimenting with
OpenGL and GLUT. When using one of the sample files for loading models,
on compilation I get the following error.

Example1.obj : error LNK2001: unresolved external symbol "void __cdecl
glmDelete(struct GLMmodel *)" (? glmDelete@@YAXPAUGLMmodel@@@Z)

Now, is this caused by an error in my code, or is it caused by an error
in the sample file I'm including?

Thanks
Connell

My guess is it's an extern "C" issue.

-JKop
 
J

jeffc

Connell Gauld said:
Hi,
I am quite new to C++ programming and I have been experimenting with
OpenGL and GLUT. When using one of the sample files for loading models,
on compilation I get the following error.

Example1.obj : error LNK2001: unresolved external symbol "void __cdecl
glmDelete(struct GLMmodel *)" (?glmDelete@@YAXPAUGLMmodel@@@Z)

Now, is this caused by an error in my code, or is it caused by an error
in the sample file I'm including?

You'll have to check a microsoft newsgroup for Visual C++ - it's not a C++
language problem per se.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,778
Messages
2,569,605
Members
45,237
Latest member
AvivMNS

Latest Threads

Top