CrossCompile

Philip Balister edited this page Dec 18, 2013 · 3 revisions
Clone this wiki locally

I assume you already know how to build gnuradio natively.

  1. Build the cross toolchain with OpenEmbedded:

bitbake -c populate_sdk gnuradio-dev-image

  1. Find the sdk:

    $ ls tmp-eglibc/deploy/sdk/
    oecore-x86_64-armv7a-vfp-neon-toolchain-nodistro.0.sh

  2. Install the sdk:

'$ sudo sh tmp-eglibc/deploy/sdk/oecore-x86_64-armv7a-vfp-neon-toolchain-nodistro.0.sh`

  1. Source the environment file.

$ . /usr/local/oecore-x86_64/environment-setup-armv7a-vfp-neon-oe-linux-gnueabi

  1. Make the build directory in the gnuradio source directory.

$ mkdir build-arm

  1. Run cmake.

$ cmake -Wno-dev -DCMAKE_TOOLCHAIN_FILE=../cmake/Toolchains/oe-sdk_cross.cmake -DENABLE_GR_ATSC=OFF -DENABLE_GR_VOCODER=OFF ../

  1. Build GNU Radio

$ make -j 8

  1. Mount your home directory via sshfs. Do this on the target. Replace username with yours.

# mkdir /home/username # sshfs -o allow_root username@host: /home/user

  1. On the target run the QA code. Adjust path to match your setup.

# cd /home/username/gnuradio/build # make test