|
-
August 26th, 2008, 11:13 AM
#2
Re: How to include my own function source code?
It's not enough to #include the header. That only provides enough information for the compiler to verify the functions in the header are being called properly. In order to actually *use* the functions, you must compile the .cpp as well and link it with your code.
Either add the .cpp to your project, or compile it into a static library and link it with your project.
Unresolved external symbol means *exactly* what it says. There's an external symbol (something from the .h file) which the linker can't resolve, because it doesn't have access to the cpp file that defines it.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|