LeapFrog Pollux Platform: Build Environment
A build environment allows you to compile a kernel, root file system, or programs for use on your device. Commonly referred to as Cross Compiling, this will set up your Linux host PC to build for a different architecture, in this case the Pollux(LF1000) SoC.
This should be extracted to the /opt directory.
sudo tar -xjvf RidgeRun-toolchain-369009.tar.bz2 -C /
Source Code The source code for your particular application can be extracted pretty much anywhere. A project folder in your home directory works well.
Tip: Set it up so you can have multiple source trees parallel to each other. Keep an untouched tree in this directory, along with trees for different major changes you are working on. This makes it easy to create and roll back patches, and keeps modifications organized and sensible.
Once you got your toolchain and source code in their respective directories, you'll need to set up some environmental variables for the cross compiling, and the build scripts. The following paths should be copy and pasted into a text file, crosscompile_env_vars, and stored in your source code parent directory.
export WORK_DIR=$PWD export CROSS_COMPILER_ROOT=/opt/RidgeRun/arm-eabi-uclibc export PATH=$CROSS_COMPILER_ROOT/bin/:$PATH export CROSS_COMPILE=arm-linux- export UBOOT_CROSS_COMPILE=arm-linux- export TARGET_MACH=LF_LF1000 export ROOTFS_PATH=$WORK_DIR/target/rootfs/ export EROOTFS_PATH=$WORK_DIR/target/erootfs/ export TFTP_PATH=$WORK_DIR/target/tftp/ export RELEASE_PATH=$WORK_DIR/target/release/
You need to use the command line to build the source code, so open up a terminal and go to the source code you want to build. If you run ls you should see linux-2.6/ packages/ and scripts/ from here you want to set your environment variables, as they are set up based on what directory you are in.
This will set your current terminal shell with these variables, if you close it, or use another one, you need to reset these variables by running that command.
You are now set up to start compiling for the LeapFrog Pollux Platform.