发布于2024-12-08 09:58 阅读(427) 评论(0) 点赞(22) 收藏(2)
I've got the following structure of conanfile.py for the purpose of installing boost in my macOS build machine. Apparently some boost components are not supported in this platform and should be omitted according to this post. Thus I need to apply the following settings. However, this is how they are configured in conanfile.txt, and I'm already working with conanfile.py, so I need to find the equivalent python code to this settings :
[options]
boost/*:with_stacktrace_backtrace=False
boost/*:without_locale=True
and here's my attempt to apply this configuration in conanfile.py.
from conan2 import ConanFile
class BoostExampleConan(ConanFile):
name = "BoostExample"
version = "1.0"
settings = "os", "compiler", "build_type", "arch"
requires = "boost/1.83.0"
generators = "CMakeDeps", "CMakeToolchain"
default_options = {
"boost:header_only": False
--> "boost:with_stacktrace_backtrace"=False
--> "boost:without_locale"=True
}
def layout(self):
self.folders.source = "."
self.folders.build = "build"
However, I still get the following error :
boost/1.83.0: WARN: Boost component 'locale' is missing libraries. Try building boost with '-o boost:without_locale'. (Option is not guaranteed to exist)
boost/1.83.0: WARN: Boost component 'stacktrace_addr2line' is missing libraries. Try building boost with '-o boost:without_stacktrace_addr2line'. (Option is not guaranteed to exist)
boost/1.83.0: WARN: Boost component 'stacktrace_backtrace' is missing libraries. Try building boost with '-o boost:without_stacktrace_backtrace'. (Option is not guaranteed to exist)
ERROR: boost/1.83.0: Error in package_info() method, line 2011
raise ConanException(f"These libraries were expected to be built, but were not built: {non_built}")
ConanException: These libraries were expected to be built, but were not built: {'boost_locale', 'boost_stacktrace_backtrace', 'boost_stacktrace_addr2line'}
作者:黑洞官方问答小能手
链接:https://www.pythonheidong.com/blog/article/2046420/823f3ef03ad417d42e15/
来源:python黑洞网
任何形式的转载都请注明出处,如有侵权 一经发现 必将追究其法律责任
昵称:
评论内容:(最多支持255个字符)
---无人问津也好,技不如人也罢,你都要试着安静下来,去做自己该做的事,而不是让内心的烦躁、焦虑,坏掉你本来就不多的热情和定力
Copyright © 2018-2021 python黑洞网 All Rights Reserved 版权所有,并保留所有权利。 京ICP备18063182号-1
投诉与举报,广告合作请联系vgs_info@163.com或QQ3083709327
免责声明:网站文章均由用户上传,仅供读者学习交流使用,禁止用做商业用途。若文章涉及色情,反动,侵权等违法信息,请向我们举报,一经核实我们会立即删除!