In this post, we will show the steps to build kernel for pcDuino3. There is a sister post about building the kernel for pcDuino1/2. Before we can start the real work, we need to setup a X86-64 virtual box cross compilation environment. Please refer to this post for detailed information. The cross compiler should be of version 4.6.
1. Setup the environment
A. For the new system, we need to install some dependency software
#sudo apt-get install build-essential git u-boot-tools texinfo texlive ccache zlib1g-dev gawk bison flex gettext uuid-dev ia32-libs
B. Install the cross compiler
#sudo apt-get install g++-arm-linux-gnueabihf
2. Download kernel source files of pcDuino3
We need to create a working directory first, for example, a20-kernel.
The source files are hosted at github.
#git clone https://github.com/pcduino/a20-kernel
After download, we can check the contents of the kernel project:
3. Now we can proceed to build the kernel using ‘make’ command
#make <img class="alignnone" src="http://cnlearn.linksprite.com/wp-content/uploads/2014/04/3.png" alt="" width="901" height="461" />
The generated files are located under output directory:
The files generated has date in the file name. pcduino3_a20_hwpack_20140415.tar.xz includes all the generated files, such has uImage ,u-boot,ko, etc. They are very important for the rootfs. pcduino3_a20_kernel_livesuit_20140415.img is the image that will be burned on to the SD card using PhoenixCard_V309.
September 20, 2014 at 6:30 am
I am running Ubuntu 14.04 and tried step A, and got this message:
Package ia32-libs is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
lib32z1 lib32ncurses5 lib32bz2-1.0
E: Package ‘ia32-libs’ has no installation candidate
October 1, 2014 at 11:36 am
Hi did you update your package list?
sudo apt-get update
September 30, 2014 at 9:25 pm
Stephen, Hopefully you already figured this out, but just apt-get install those packages and it will work fine. I’m also using 14.04 without any problems.
October 5, 2014 at 2:14 pm
I had to install various packages in order to make it work :
sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 libusb-1.0-0-dev pkg-config