Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Multiply defined symbols found?

Tags:

c++

static

I made my own library and compiled it as a static library in MSVC using the MD multithreaded DLL runtime. I then compiled my application and included myLib.lib and when I do I get tons of multiply defined symbols relating to MSVCRTLIB, what am I doing wrong?

Thanks

like image 816
jmasterx Avatar asked Apr 08 '26 10:04

jmasterx


1 Answers

The application and all libraries must be compiled with the same settings. Make sure they all use the MD option.

like image 160
Mark Ransom Avatar answered Apr 11 '26 00:04

Mark Ransom



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!