我试图在Ubuntu 18 Linux系统上的单独路径中构建boost。我克隆了GIT存储库,因为我想拥有最新版本(软件包存储库仅提供旧版本)。我要使用的库是boost::timer
。
这是我所做的:
git clone --recursive https://github.com/boostorg/boost.git
cd boost
./bootstrap.sh
./b2 headers
./b2
这种工作。但是我希望静态库位于其他路径中。它被编译成以下路径:
... / boost / bin.v2 / libs / timer / build / gcc-9 / release / link-static / threading-multi / visibility-hidden / libboost_timer.a
此路径非常冗长,它包含编译器及其版本,这意味着我在更新GCC或更改编译器时需要更新路径。
我会在这里期望它:
... / boost / libs / timer / libboost_timer.a
我做错什么了吗?预计会这样放置吗?
[好,当仔细阅读构建输出时,即使像我这样的傻瓜也可能会注意到实际路径是boost/stage/lib
。可以在此处找到所有内置的库。