Archived

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

Libary conflict when using MFC

This topic is 5311 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 built a library file for a scripting language I created. I have used it and it works fine in console mode programs, but I tried to use it with a program that uses MFC, and I get a bunch of linking conflict errors (functions already defined) when I try to build. They are mostly standard C functions I think. It sure seems as if some standard C functions are getting linked into my library, yet it works fine with console mode programs. Also, when building a library, it doesn''t give me the option to build without the standard libraries, as it does when I build an executable.

Share this post


Link to post
Share on other sites
Check your build settings. Make sure you are linking against the same runtime libraries (single-threaded vs multi-threaded). The default setting for a library is single-threaded. The default for an MFC app is multi-threaded DLL.

Share this post


Link to post
Share on other sites