【问题标题】:could not detect boost libraries when running ./configure when compiling bitcoin core code编译比特币核心代码时运行./configure时无法检测到boost库
【发布时间】:2021-03-19 22:33:30
【问题描述】:

这是我得到的错误:

checking for boostlib >= 1.58.0 (105800)... configure: 
We could not detect the boost libraries (version 1.58.0 or higher). 
If you have a staged boost library (still not installed) please specify $BOOST_ROOT in your environment and do not give a PATH to --with-boost option.  
If you are sure you have boost installed, then check your version number looking in <boost/version.hpp>. See http://randspringer.de/boost for more documentation.
configure: error: Boost is not available!

我使用的是最新版本的 macOS big sur,并使用自制软件安装了 boost。我认为 boost 应该安装在 usr/local/include 中,但对我来说,它安装在 /opt/homebrew/opt/boost 中。这可能是问题吗?我使用符号链接从 usr/local/include 转到 /opt/homebrew/opt/boost 但是当我进入比特币文件夹然后运行 ​​./configure 时它不起作用。

【问题讨论】:

  • 如果在构建之前运行export BOOST_ROOT=/opt/homebrew/opt/boost 会怎样?
  • config.log 包含配置脚本诊断输出的副本。您可以在此日志文件中找到 configure 脚本试图编译的测试程序,以检测 boost 库的可用性。基于此,应该可以确定编译失败的原因,以及如何修复它。

标签: boost bitcoin


【解决方案1】:
    export BOOST_ROOT=/opt/homebrew/opt/boost
    ./configure --with-gui=no --without-bdb --with-boost=$BOOST_ROOT

您的选择可能不同

【讨论】:

  • 这在macos中对我有用./configure --prefix=$PWD/depends/arm-apple-darwin20.2.0 --with-boost=$BOOST_ROOT
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2015-03-17
  • 1970-01-01
  • 2021-02-16
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多