Distribute a program compiled with MinGW g++

前端 未结 5 874
夕颜
夕颜 2021-01-05 08:31

Let\'s say I have created and compiled a simple program using the MinGW 64 (g++ compiler). Running this program on my computer and looking in Process Explorer for what DLL f

5条回答
  •  走了就别回头了
    2021-01-05 08:59

    libstdc++6.dll is the C++ standard library, like you said.

    libwinpthread-1.dll is for C++11 threading support. MinGW-W64 has two possible thread variants: Either use the native Windows functions like CreateThread, but C++11 stuff like std::thread won´t be available then; or include this library and use the C++11 classes (too).
    Note that to switch the thread model, you´ll need to reinstall MinGW. Just removing the DLL and not using the C++11 stuff won´t work, the DLL will be required nonetheless with your current install.

    libgcc_s_seh-1.dll is something about C++ exception handling.

    Yes, it should be sufficient to deliver the DLLs too
    (or use static linking and deliver only your program file).

提交回复
热议问题