理论上boost需要用b2
构建。在我的例子中,使用 b2 --build-dir=c:\boost\--toolset=msvc 完成阶段
。
这会产生一个警告 the --build-dir option was specified but Jamroot at '.'未指定项目 ID --build-dir 选项将被忽略
(看起来无害),然后是致命通知 [sic] `
could not find main target complete
assuming it is a name of file to create.
could not find main target stage
assuming it is a name of file to create.
显然目标已重命名。构建的正确目标是什么?
谷歌搜索只找到几个匹配项,当前 (1.54.0) Boost 版本没有。
最佳答案
可识别的目标名称取决于构建类型。由于命令行缺少 --buildtype=
,因此下一个标记 complete
被错误地解释为目标并且无法识别。下一个标记 stage
是一个目标,但由于未设置构建类型而无法识别。
关于c++ - 当 "b2"不起作用时如何构建 Boost,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17785938/