将 -L 添加到 bjam 中的项目中
我的项目中有 boost_iostreams,它依赖于 bzip2 和 zlib。因此,运行
export LIBRARY_PATH=/apps/bzip2/lib:/apps/zlib/lib
然后运行 bjam link=static
就可以了。
有没有办法在 Jamroot 中设置它,以便不需要环境变量?
当前 Jamroot :
project infracore
: requirements
<include>$(PROJECT_ROOT)_install
<include>$(BOOST_INCLUDE_BASE)
<include>$(BZIP2_INCLUDE_BASE)
<library>/boost/filesystem//boost_filesystem
<library>/boost/system//boost_system
<library>/boost/date_time//boost_date_time
<library>/boost/iostreams//boost_iostreams
<variant>debug:<inlining>off
<variant>debug:<debug-symbols>on
<variant>debug:<optimization>off
<variant>debug:<warnings>on
<variant>release:<warnings>on
<link>static
;
# Libraries
build-project UtilsCode ;
build-project ProfilerCode ;
build-project CommonDataStructuresCode ;
build-project Math ;
# Executibles
build-project fixfast ;
build-project Tools ;
build-project RiskConsole ; #u2ic
I have boost_iostreams in my project and it depends on bzip2 and zlib. Hence running
export LIBRARY_PATH=/apps/bzip2/lib:/apps/zlib/lib
and then running bjam link=static
works.
Is there a way to set this in the Jamroot, so that the environment variable is not needed ?
Current Jamroot :
project infracore
: requirements
<include>$(PROJECT_ROOT)_install
<include>$(BOOST_INCLUDE_BASE)
<include>$(BZIP2_INCLUDE_BASE)
<library>/boost/filesystem//boost_filesystem
<library>/boost/system//boost_system
<library>/boost/date_time//boost_date_time
<library>/boost/iostreams//boost_iostreams
<variant>debug:<inlining>off
<variant>debug:<debug-symbols>on
<variant>debug:<optimization>off
<variant>debug:<warnings>on
<variant>release:<warnings>on
<link>static
;
# Libraries
build-project UtilsCode ;
build-project ProfilerCode ;
build-project CommonDataStructuresCode ;
build-project Math ;
# Executibles
build-project fixfast ;
build-project Tools ;
build-project RiskConsole ; #u2ic
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
试试这个:
Try this: