By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,116 Members | 1,509 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,116 IT Pros & Developers. It's quick & easy.

Errors during linking

P: 8
whenever i make a graphic program in c/c++ program compiles.. but while executing gives linker errors....
Sep 8 '10 #1
Share this Question
Share on Google+
3 Replies

Expert Mod 5K+
P: 8,916
The linker does not run as part of execution it runs after the compilation as part of the build process.

If you are getting linker errors then you may be missing 1 or more libraries from the link command or it may be something simple like a typo causing a misspelled function name.

What are the errors?
Sep 8 '10 #2

P: 8
for all the functions which are defined in <graphics.h> its giving undefined symbol..
eg initgraph
Sep 8 '10 #3

Expert Mod 5K+
P: 8,916
You have presumably then not linked against the library that contains the functions declared in graphics.h

I don't know what that library is since graphics.h is not a standard header but a wild stab in the dark guess would be graphics.lib. Anyway whatever the library name is you will need to add it to you link command line.
Sep 8 '10 #4

Post your reply

Sign in to post your reply or Sign up for a free account.