What do we need: * QEMU ARM Emulator (download binaries from http://www.qemu.org) * GNU ARM toolchain (download binaries from http://www.gnuarm.com/) * Linux kernel source (download from http://www.kernel.org) * textinfo == Setting up Development Environment == === QEMU ARM Emulator Installation === TBD. === Colinux Installation === === Download, Install, Run === ==== Create a Disk for ARM Development ==== 1. Create 3GB blank file with Cygwin: {{{ # under cygwin! $ cd /cygdrive/path/to/colinux $ dd if=/dev/zero of=disk_armdev bs=1k count=3000000 }}} (note: the above count is ''three million''). 1. Stop Colinux: {{{ # from colinux: $ shutdown -h now }}} 1. Edit your configuration: {{{ cobd3=f:\colinux\disk_armdev }}} 1. Restart colinux: {{{ net start colinux }}} 1. Format and mount the new disk: {{{ # In colinux: $ mkfs -t ext3 /dev/cobd3 $ mkdir /arm $ mount /dev/cobd3 /arm }}} === Directory Structure === {{{ /arm/download /arm/srcs /arm/objs }}} == Tools == === Download Latest binutils, GCC, and newlib === binutils: http://ftp.gnu.org/gnu/binutils/ GCC: http://ftp.gnu.org/gnu/gcc/ newlib: ftp://sources.redhat.com/pub/newlib/index.html {{{ $ mkdir -p /arm/download $ cd /arm/download $ wget -c http://ftp.gnu.org/gnu/binutils/binutils-2.18.tar.bz2 $ wget -c http://ftp.gnu.org/gnu/gcc/gcc-3.4.6/gcc-3.4.6.tar.bz2 $ wget -c ftp://sources.redhat.com/pub/newlib/newlib-1.16.0.tar.gz }}} === Preparing to build === ==== Unpack archives ==== {{{ $ mkdir -p /arm/srcs $ cd /arm/srcs $ tar xjf ../download/binutils-2.18.tar.bz2 $ tar xjf ../download/gcc-3.4.6.tar.bz2 $ tar xzf ../download/newlib-1.16.0.tar.gz }}} ==== Prepare newlib to be built along with gcc ==== {{{ $ cd gcc-3.4.6 $ ln -s ../newlib-1.16.0/newlib . $ cd .. }}} === Build Everything === ==== Build binutils ==== {{{ $ mkdir -p /arm/objs/binutils-arm $ cd /arm/objs/binutils-arm $ ../../srcs/binutils-2.18/configure --target=arm-elf --prefix=/arm $ make $ cd .. }}} ==== Update binutils Path ==== Before we build gcc below, we need to first add the path to (thew newly installed) binutils: {{{ $ export PATH=/arm/bin:$PATH }}} ==== Build gcc ==== {{{ $ mkdir /arm/objs/gcc-arm $ cd /arm/objs/gcc-arm $ ./../srcs/gcc-3.4.6/configure --target=arm-elf --prefix=/arm --enable-threads \ --with-cpu=arm9 --enable-languages=c --disable-nls \ --with-newlib $ make $ make install }}} == PJSIP == === Build === {{{ $ cd /your/pjproject/directory $ make distclean $ ./aconfigure --host=arm-elf --disable-floating-point --disable-sound $ cat << EOF > user.mak export CFLAGS += -msoft-float EOF $ make dep $ make }}}