【问题标题】:Boost.Python installation failing with bjam errorsBoost.Python 安装失败并出现 bjam 错误
【发布时间】:2012-12-21 08:44:34
【问题描述】:

我一直在努力让 Boost.Python 运行。

我正在遵循http://www.boost.org/doc/libs/1_41_0/libs/python/doc/building.html 中提到的步骤。我遵循了第 3.1 节第 2 步。 Bjam 司机让我头疼。因此,如文档中所述,我遵循http://www.boost.org/doc/libs/1_41_0/more/getting_started/windows.html#or-simplified-build-from-source 第 5 节中概述的步骤。

尝试第 5.2 节时出现以下错误:

C:\Program Files (x86)\boost\boost_1_50>.\bootstrap

Building Boost.Build engine

The system cannot find the path specified.

'.\build.bat' is not recognized as an internal or external command,

operable program or batch file.


Failed to build Boost.Build engine.

Please consult bootstrap.log for furter diagnostics.


You can try to obtain a prebuilt binary from


   http://sf.net/project/showfiles.php?group_id=7586&package_id=7294

1

因此,由于这次尝试失败,我尝试采用 5.3 中概述的步骤。我下载了一个 jam zip 文件。然后构建一个 jam.exe 可执行文件,然后将 bjam exe 添加到 PATH 环境变量中。所以现在尝试这样做

bjam --build-dir=build-directory toolset=toolset-name --build-type=complete 阶段

C:\Program Files (x86)\boost\boost_1_50>bjam --build-dir="C:\build-boost" 工具 t=msvc --build-type=完成阶段

失败并出现以下错误....

    C:\Program Files (x86)\boost\boost_1_50>bjam --build-dir="C:\build-boost" toolse
    t=msvc --build-type=complete stage

    Unable to load Boost.Build: could not find build system.
    ---------------------------------------------------------
    C:\Program Files (x86)\boost\boost_1_50\boost-build.jam attempted to load the bu
    ild system by invoking

       'boost-build tools/build/v2 ;'

    but we were unable to find "bootstrap.jam" in the specified directory
    or in BOOST_BUILD_PATH (searching C:\Program Files (x86)\boost\boost_1_50\tools/
    build/v2).

Please consult the documentation at 'http://www.boost.org'.

C:\Program Files (x86)\boost\boost_1_50>

现在我的 boost 主目录中不存在目录 tools/build/v2 .. 所以我重新下载了 boost 包并重复了所有步骤。仍然没有成功。现在我不知道该怎么办..

我想获取在 libs/python/example/quickstart/ up and running 的 boost 安装下给出的示例。

有人可以帮忙安装吗?

编辑::

在我看来,boost-build.jam 文件包含以下条目

BOOST_BUILD ?= tools/build/v2 ;

但是我没有这个工具目录?? boost 目录结构是否已更改。 ?我应该期望我的 Boost 安装有一个“工具”目录吗?我也找不到文件“bootstrap.jam”?

【问题讨论】:

  • 看起来您从 boostpro 安装了预构建的 boost 库。您不需要构建任何东西,只需在安装程序的组件下选择正确的Boost.Python 库即可。

标签: python boost boost-python bjam


【解决方案1】:

好的,我发现了问题所在。我从 BoostPro 而不是 Boost.org 下载了 boost 配置文件。好吧,因为我是一个新手,直到它严重打击我才意识到这一点。我在 Boost.org 上查看官方提升文档,显然存在一些差异。现在很好:-)

【讨论】:

  • 你能解释一下你是如何解决这个问题的吗?
  • @maheshakya 我下载了错误的 Boost 包。我没有从 Boost.org 下载,而是下载了 BoostPro 。它们需要稍有不同的环境。请小心您下载的内容,并严格按照 Boost 版本的说明进行操作。
猜你喜欢
  • 2017-08-28
  • 1970-01-01
  • 2021-07-31
  • 2016-11-08
  • 1970-01-01
  • 2014-06-01
  • 2021-11-08
  • 2017-11-29
  • 1970-01-01
相关资源
最近更新 更多