• SCons. Arm has tested SCons 2.4.1, other versions might work.
• CMake. Arm has tested CMake 3.5.1, other versions might work.
• Boost. Arm have tested version 1.64.
• Protobuf. Arm has tested version 3.5.0.
• ARM NN SDK
• Compute Library
• Caffe及相关
Building Boost.Build engine with toolset gcc… tools/build/src/engine/bin.linuxx86_64/b2
Detecting Python version… 2.7
Detecting Python root… /opt/fsl-imx-wayland/4.9.51-mx8-ga/sysroots/x86_64-pokysdk-linux/usr
Unicode/ICU support for Boost.Regex?.. not found.
Generating Boost.Build configuration in project-config.jam…
Bootstrapping is done. To build, run:
./b2
To adjust configuration, edit ‘project-config.jam’.
Further information:
-Command line help:
./b2 --help
- Getting started guide: http://www.boost.org/more/getting_started/unix-variants.html
- Boost.Build documentation: http://www.boost.org/build/doc/html/index.html
修改修改project-config.jam文件
if ! gcc in [ feature.values ]
{
using gcc : arm : aarch64-poky-linux-gcc --sysroot=$SDKTARGETSYSROOT
}//注意冒号后面的空格若为32位平台则如下
if ! gcc in [ feature.values ]
{
using gcc : arm : arm-linux-gnueabihf-gcc ;
}//注意编译的时候要是能你的编译器的环境变量
BLAS: apt-get install libatlas-base-dev or install OpenBLAS by sudo apt-get install libopenblas-dev or MKL for better CPU performance.
Python (optional): if you use the default Python you will need to sudo apt-get install the python-dev package to have the Python headers for building the pycaffe interface.
apt-get install libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libhdf5-serial-dev protobuf-compiler
apt-get install --no-install-recommends libboost-all-dev
apt-get install libgflags-dev libgoogle-glog-dev liblmdb-dev
安装完成之后进入caffe目录
mkdir build
cmake …
make all
make install
make runtest
make all时汇报很多错误,在错误的开头会提示
error This file requires compiler and library support for the ISO C++ 2011 standard. This support is currently experimental, and must be enabled with the -std=c++11
or -std=gnu++11 compiler options.