-
Notifications
You must be signed in to change notification settings - Fork 800
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiple definition errors when including mimalloc-new-delete.h. #559
Comments
This sounds a lot like #535, have a look there |
@res2k thanks for the quick response.
I installed mimalloc using Am I understanding it correctly? |
As the official doc stated clearly https://microsoft.github.io/mimalloc/using.html
the tricky part is You either link to mimalloc with MI_OVERRIDE=0 and with You can test with For instance a.h
a.cpp
And then link with mimalloc |
I am trying to override the new/delete operators as suggested in the documentation. I am using vcpkg and added the following statements in my CMakeLists.txt file:
My program compiles just fine with the above changes but when I include
mimalloc-new-delete.h
, it starts to give linker errors as follows:How do I avoid these multiple definition errors? Any help is appreciated. Thanks in advance !
The text was updated successfully, but these errors were encountered: