본문 바로가기

Linux

boost : cross compile

[출처] : http://www.cnx-software.com/2011/10/03/cross-compiling-boost-c-libraries-for-arm/

Boost provides free peer-reviewed portable C++ source libraries. Ten Boost libraries are already included in the C++ Standards Committee’s Library Technical Report and will be in the new C++11 Standard.

The Boost C++ libraries are already included in popular Linux and Unix distributions such as Fedora, Debian, Ubuntu and NetBSD and are used by projects such as Python, Xibo, Civilization IV, etc..

Here are the steps to cross-compile Boost C++ libraries for arm using arm-linux-guneabi-g++:

  1. Download the source code:
    wget http://sourceforge.net/projects/boost/files/boost/1.47.0/boost_1_47_0.tar.bz2/download
  2. Extract the source code:
    mv download boost.tar.bz2
    tar xjvf boost.tar.bz2
    cd boost_1_47_0/
  3. Bootstrap the code:
    ./bootstrap.sh
  4. Modify the configuration file (project-build.jam) to use the ARM toolchain by replacing the line with “using gcc” by:
    using gcc : arm : arm-linux-gnueabi-g++ ;
  5. Install the python development package:
    sudo apt-get install python-dev
  6. Build and install the boost libraries:
    ./bjam install toolset=gcc-arm --prefix=~/edev/beagleboard/libs --disable-long-double -sNO_ZLIB=1 -sNO_BZIP2=1

This was tested in Ubuntu 11.04 (natty) and 10.04 LTS with linaro g++ toolchain.



Read more: http://www.cnx-software.com/2011/10/03/cross-compiling-boost-c-libraries-for-arm/#ixzz3eQvAlukM

'Linux' 카테고리의 다른 글

diff 폴더 비교하기  (0) 2015.12.08
minicom 사용법  (0) 2015.11.08
ssh 자동 로그인하기.  (0) 2015.06.13
Makefile에서 대소문자 변환하기  (0) 2015.04.07
DirectFB API 설명  (0) 2014.12.22