开发者

Dynamic link to the MinGW runtime

开发者 https://www.devze.com 2023-03-21 08:50 出处:网络
I read somewhere that MinGW statically links the c/c++ runtime. How can I dynamicallylink them to reduce the executable size? I don\'t need to worry about the dependency issue, as the final program wi

I read somewhere that MinGW statically links the c/c++ runtime. How can I dynamically link them to reduce the executable size? I don't need to worry about the dependency issue, as the final program will run on a Linux box. I am just doing a proof-of-concept prototype on windows, and need to 开发者_JS百科show that the produced executable is very small.


Link with -shared-libgcc, as usual. However, beware that the standard Debian mingw is built without shared libgcc support (though we have a version in our repository where I enabled that).

0

精彩评论

暂无评论...
验证码 换一张
取 消