Search code examples
c++dllexecodeblockssfml

Why are there errors while opening code::blocks exe file?


I finished my little project on the IDE codeblocks, now I want to open the exe file, I added the SFML DLLs, but when opening, this happens:

Procedure entry point _ZNKSt7__cxx1112basic_stringlcSt11char_traitslcESalcEE12find_last_ofEPKcjj _ZNKSt7__cxx1112basic_stringlcSt11char_traitslcESalcEE7reserveEj ... can not be found in the dynamic link library

What is the problem? Do I have to add something?


Solution

  • These errors are caused by mismatched dll files. It maybe the case that a libstdc++-6.dll is also in the WINDOWS\System32 directory. If you don't have one, download it.

    1. Go into your MinGW/bin folder,
    2. Copy libstdc++-6.dll to the same folder as your exe file.

    Try copying this dll to System32 if this does not work.

    You can refer DLL and run Dependency walker too.