如何构建Boost :: program_options [英] How to build Boost::program_options
问题描述
我想使用boost :: program_options.安装Boost之后,我认为我必须分别构建program_options(http://www.boost.org/doc/libs/1_43_0/more/getting_started/windows.html ).但是我不知道该怎么做.
I wanted to use boost::program_options. After I installed boost, I think that I have to build separatly program_options (http://www.boost.org/doc/libs/1_43_0/more/getting_started/windows.html). But I don't know how to do it.
我正在尝试编译C:\ Program Files \ boost \ boost_1_42 \ libs \ program_options \ example \ first.cpp(
I am trying to compile the C:\Program Files\boost\boost_1_42\libs\program_options\example\first.cpp (http://www.boost.org/doc/libs/1_42_0/doc/html/program_options/tutorial.html) but probably due to I didn't build the library I have this error:
LINK : fatal error LNK1104: cannot open file 'libboost_program_options-vc90-mt-gd-1_42.lib'
编辑:我使用了BoostPro Computing提供的安装程序,因此跳过了二进制文件的安装(
EDIT: I used the installers supplied by BoostPro Computing so I skipped the installation of the binaries (http://www.boost.org/doc/libs/1_43_0/more/getting_started/windows.html#install-visual-studio-binaries)
编辑:我还按照推荐答案
阅读 Boost 1.54 Windows入门指南,这些是您应该采取的步骤( After reading the Boost 1.54 Getting Started on Windows guide these are the steps that you should take ( 从此处下载Boost的源代码并安装它. 从命令行(最好是VS的开发人员命令提示符): From a command line (preferably the Developer Command Prompt for VS): 这将在几分钟内完成,仅此而已!这些库位于目录 This will finish in a couple of minutes and that's it! The libraries are located in the directory 顺便说一句,您可以看到可以使用 BTW you could see which libraries you can build using 这篇关于如何构建Boost :: program_options的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!program_options
is a header only library). You need to have a MSVC compiler installed. bootstrap.bat
bjam.exe --build-type = complete msvc stage --with-program_options
.\ bin.v2 \ libs \ program_options \ build
中..\bin.v2\libs\program_options\build
. bjam --show-libraries
构建哪些库.bjam --show-libraries
.