【发布时间】:2017-10-12 15:25:33
【问题描述】:
我需要交叉编译 power-pc 的 boost 库。
请在下面找到我为使其运行而执行的步骤:
我已经
- 下载了 boost 1.61
- 在/home/emh2下解压
- 并执行 sudo ./home/bootstrap.sh 来提升构建器 b2
- Boost.Builder b2 已成功创建。
交叉编译器powerpc-bt-linux-gnuspe-g++位于以下路径下:
/usr/local/cross/i686-bt-linux/usr/bin/powerpc-bt-linux-gnuspe/
交叉编译器的包含目录如下
/usr/local/cross/ppce500v2-bt-linux-gnuspe/usr/include/c++/5.2.0/powerpc-bt-linux-gnuspe
/usr/local/cross/ppce500v2-bt-linux-gnuspe/usr/include/c++/5.2.0/
/usr/local/cross/ppce500v2-bt-linux-gnuspe/usr/include/
接下来我在 /home 中创建了具有以下内容的 user-config.jam:
using gcc
: ppc
: /usr/local/cross/i686-bt-linux/usr/bin/powerpc-bt-linux-gnuspe/powerpc-bt-linux-gnuspe-g++
: <compilerflags>-I/usr/local/cross/ppce500v2-bt-linux-gnuspe/usr/include/c++/5.2.0/powerpc-bt-linux-gnuspe -I/usr/local/cross/ppce500v2-bt-linux-gnuspe/usr/include/c++/5.2.0/ -I/usr/local/cross/ppce500v2-bt-linux-gnuspe/usr/include/ ;
然后我开始交叉编译
./b2 工具集=gcc-ppc --with-log
这里的输出表明找不到文件/目录:
Performing configuration checks
- 32-bit : yes (cached)
- arm : no (cached)
- mips1 : no (cached)
- power : yes (cached)
Building the Boost C++ Libraries.
- symlinks supported : yes (cached)
- compiler-supports-visibility : yes (cached)
- has_icu builds : no (cached)
- lockfree boost::atomic_flag : no (cached)
Component configuration:
- atomic : not building
- chrono : not building
- container : not building
- context : not building
- coroutine : not building
- coroutine2 : not building
- date_time : not building
- exception : not building
- filesystem : not building
- graph : not building
- graph_parallel : not building
- iostreams : not building
- locale : not building
- log : building
- math : not building
- metaparse : not building
- mpi : not building
- program_options : not building
- python : not building
- random : not building
- regex : not building
- serialization : not building
- signals : not building
- system : not building
- test : not building
- thread : not building
- timer : not building
- type_erasure : not building
- wave : not building
...patience...
...patience...
...patience...
...patience...
...found 4056 targets...
...updating 208 targets...
gcc.compile.c++ bin.v2/libs/atomic/build/gcc-ppc/release/threading- multi/lockpool.o
libs/atomic/src/lockpool.cpp:15:19: fatal error: cstddef: No such file or directory
compilation terminated.
"/usr/local/cross/i686-bt-linux/usr/bin/powerpc-bt-linux-gnuspe/powerpc-bt-linux-gnuspe-g++" -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall -pthread -fPIC -m32 -DBOOST_ALL_NO_LIB=1 -DBOOST_ATOMIC_DYN_LINK=1 -DBOOST_ATOMIC_SOURCE -DNDEBUG -I"." -c -o "bin.v2/libs/atomic/build/gcc-ppc /release/threading-multi/lockpool.o" "libs/atomic/src/lockpool.cpp"
...failed gcc.compile.c++ bin.v2/libs/atomic/build/gcc-ppc/release/threading- multi/lockpool.o...
...skipped <pbin.v2/libs/atomic/build/gcc-ppc/release/threading- multi>libboost_atomic.so.1.61.0 for lack of <pbin.v2/libs/atomic/build/gcc-ppc /release/threading-multi>lockpool.o...
...skipped <pstage/lib>libboost_atomic.so.1.61.0 for lack of <pbin.v2/libs /atomic/build/gcc-ppc/release/threading-multi>libboost_atomic.so.1.61.0...
...skipped <pstage/lib>libboost_atomic.so for lack of <pstage/lib>libboost_atomic.so.1.61.0...
gcc.compile.c++ bin.v2/libs/date_time/build/gcc-ppc/release/threading- multi/gregorian/greg_month.o
In file included from ./boost/date_time/gregorian/greg_month.hpp:12:0,
from libs/date_time/src/gregorian/greg_month.cpp:14:
./boost/date_time/constrained_value.hpp:12:21: fatal error: exception: No such file or directory
compilation terminated.
我在这里缺少什么?为什么会出现这些“没有这样的文件或目录”错误?
【问题讨论】:
标签: linux gcc boost g++ cross-compiling