|
libstdc++-6.dll is missing? |
Desmond Taylor
Member #11,943
May 2010
|
EDIT: This has now been fixed - Pass "-static-libstdc++" in the linker options to avoid needing the .dll Hi, I have just re-installed windows with Windows 7 Ultimate 32 bit and installed Code::Blocks 10.05. I then installed MingW from their website so that I have the latest copy but... I now get this error when trying to run the Executable. With Code::Blocks that comes with MingW all set up I do not get this error. {"name":"604092","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/e\/a\/eaeea2cfff56553ab619d195a67481d2.png","w":445,"h":70,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/e\/a\/eaeea2cfff56553ab619d195a67481d2"} Is there a linker option I should know about as this is the first time me setting up my coding environment this way. Edit: Fixed Code::Blocks version since I wrote it wrong. |
AMCerasoli
Member #11,955
May 2010
|
You could follow these instructions to see if you did something wrong.
|
Desmond Taylor
Member #11,943
May 2010
|
Look at my fist post as I've already fixed it. Thanks anyway's |
Edgar Reynaldo
Major Reynaldo
May 2007
|
In case you are using C instead, use -static-libgcc to statically link the standard C library with MinGW 4.5.0. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
Desmond Taylor
Member #11,943
May 2010
|
Thanks Edgar, That will help people that are coding in C instead |
Kitty Cat
Member #2,815
October 2002
|
Note that adding -static-libstdc++ will add a good 3.2MB to your app/dll (and -static-libgcc, to avoid libgcc_s_sjlj-1.dll, adds another 100KB or so). If you're using multiple mingw-built dlls and exes, it may be better to use and provide the dynamic dlls. -- |
Edgar Reynaldo
Major Reynaldo
May 2007
|
libstdc++.a is only 2.2MB, and libgcc.a is only 116KB. If you strip unused symbols from your executable using -s after all your linking flags then you'll probably only use a small fraction of those libraries. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
Desmond Taylor
Member #11,943
May 2010
|
I already use -s and my executable is only 728KB atm. That just sets up allegro opens a window loads a bitmap and displays it twice. Edit: Updated the size because I wrote it as 8KB. |
weapon_S
Member #7,859
October 2006
|
When I pass "-static-libstdc++" and "-s" to the compiler, I will get a smaller 'distribution version' ?! That's nice to know Maybe I can static link all of those MinGW dll's... |
Desmond Taylor
Member #11,943
May 2010
|
I static linked all the ones it complains is missing so all my game needs is the media and the exe |
|