You can use -static-libstdc++ -static-libstdc++ but I haven't had success combining that with -lwinpthread: a missing dependency always popped up saying I needed *libwinpthread-1.dll. I'm using a posix cross compiler build of mingw-w64 v9.0.0/gcc version 12.2.0 on linux. After several attempts to correctly configure dosbox to use the static libraries of stdc++, gcc, and winpthreads, I was able to successfully build dosbox using the LIBS variable with the following setting: LIBS="-Wl,-Bstatic -lstdc++...
You can use -static-libstdc++ -static-libstdc++ but I haven't had success combining that with -lwinpthread: a missing dependency always popped up saying I needed *libwinpthread-1.dll. I'm using a posix build of mingw-w64 version 12.2.0 built from mingw-w64 version 9.0.0. After several attempts to correctly configure dosbox to use the static libraries of stdc++, gcc, and winpthreads, I was able to successfully build dosbox using the LIBS variable with the following setting: LIBS="-Wl,-Bstatic -lstdc++...
gcc 11.0 git build fails
Vim Git Source Code fails to compile