Replace sdd with the right device name. You can find it using sudo fdisk –l. You can also use dd instead of dcfldd. In Windows, you can use Win32 Disk Imager to write the image on to the SD card. You can find it here, Win32 Disk Imager Building u-boot, Software Preloader & Build tools Follow the instruction given in Section 4 Installing baremetal compiler tool chain to install the required tool chain. Once completed you can follow the instruction to build u-boot, software preloader & the build tool mkimage.
Unpack the archive containing the source code u-boot-altera-2012.10.tgz using
tar xvzf u-boot-altera-2012.10.tgz
Please make sure your PATH variable is set in the rightway so that the compile tool arm-none-eabi-gcc is available.
Run the following commands to start compiling u-boot & mkimage
cd u-boot-altera-2012.10
export CROSS_COMPILE=arm-none-eabi-
./MAKEALL socfpga_cyclone5
This should build u-boot.img & the tool mkimage. You can flash u-boot.img using the command (sdd3 corresponds to the 3rd partition on your microSD card)
sudo dd if=u-boot.img of=/dev/sdd3 bs=64k seek=4
Building Linux kernel Follow the instruction given in Section 5 Installing Linaro GCC to install the required toolchain. Once completed you can follow the instruction to build linux kernel
Unpack the archive containing the source code using linux-altera-3.7.tgz
tar xvzf linux-altera-3.7.tgz
Please make sure your PATH variable is set in the rightway so that the compile tool arm-linux-gnueabihf-gcc is available. Also make sure the mkimage created under u-boot-bringup/tools the previous section is available in the PATH variable. For e.g this may be done using export PATH=:$PATH
Run the following commands to start compiling linux kernel
export ARCH=arm
make socfpga_defconfig
(optional to make changes to kernel configuration)
make menuconfig
export CROSS_COMPILE=arm-linux-gnueabihf-
make uImage LOADADDR=0x8000
This will create the linux kernel image uImage under arch/arm/boot. Copy this to the corresponding microSD card partition. For e.g. (this may vary in your machine)
This will launch the GUI installer. Use the location created above as the installation path (e.g. /usr/local/codebench_2012_09_63). Proceed by clicking next. Choose add to PATH if you prefer. De-select create links options. This should install the baremetal toolchain & the binaries will be placed in /usr/local/codebench_2012_09_63/bin Installing Linaro GCC
This will launch the GUI installer. Use the location created above as the installation path (e.g. /usr/local/codebench_2012_03-57_linux). Proceed by clicking next. Choose add to PATH if you prefer. De-select create links options. This should install the toolchain 2012.03-57 for ARM GNU/Linux & the binaries will be placed in /usr/local/codebench_2012_09_63/bin