How to build boost static libs?

久未见 提交于 2019-12-04 17:42:16

问题


This works, but doesn't build static versions of boost libraries (maybe i am wrong?)

bjam --toolset=gcc --prefix=C:\boost_1_49_0-mingw install

Trying to issue folloving command:

bjam --toolset=gcc --prefix=C:\boost_1_49_0-mingw --build-type=complete install

but it doesn't work.


回答1:


You should be able to use the link=static option to let you compile the library into your binary without needing the dynamic lib:

sudo ./b2 link=static

Check your stage directory to make sure it goes in the right spot and then re-install to whatever system directory you include.



来源:https://stackoverflow.com/questions/9751271/how-to-build-boost-static-libs

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!