Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


"Undefinded Reference" x 50 :: Please help...

This topic is 6297 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I''m reading Tricks of the Windows Game Programming Gurus and I just finished chapter 8 and was doing a practice demo on the BOB Engine. I included this library called T3DLIB1.H which has a hundreds of function definitions for the engine. Well I included it in my code to (#include "T3DLIB1.H") get the function calls. But when I compile, I get over 50 "Undefined Reference" which leads to just about all my functions... I included it in my code so what the heck is wrong? I even added the code FROM the header file and put it in my .cpp file instead, and I still get 50+ "undefined reference..." errors in my linker file. If you know what I''m talking about please post the answer here <-

Share this post

Link to post
Share on other sites
Well I don''t think you included any library. What you included is probably a header file that contains prototypes of functions which are in a library. You need to add the actual library, which will have a .lib extension, not a .h extension, to your project.

How you do that depends on your linker. Check the documentation.

An undefined reference occurs when you have a prototype for a function and try to use that function with no code available for the function.


Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!