You fix this by being a knowledgeable Windows programmer.
A partial list of things.
Do not use DLLs that you are not going to ship with your exe.
The exception is known system DLLs.
Learn to use a DLL walker to confirm above.
http://www.dependencywalker.com/faq.htmlRead sites that supports learning Windows and Basic C/C++ Programming. This is NOT such a site.
Note, this is NOT a valid Code::Blocks topic; thread is likely to be locked.
Tim S.