Sonic Alert 2.8 user manual TARGETCFLAGS=-O2

Models: 2.8

1 43
Download 43 pages 27.53 Kb
Page 17
Image 17

5.3 Linux Support

17

Note that this will take a looong time2. Find something else to do while you wait.

When complete, you should find a whole slew of programs in your /opt/crosstool/gcc-3.4.3-glibc-2.3.5/arm-xscale-linux-gnu/bin/ di- rectory:

-rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x -rwxr-xr-x

1

username cvsd 1900724 Jul 18 20:48 arm-linux-addr2line

2

username cvsd 1960214 Jul 18 20:48 arm-linux-ar

2

username cvsd 3339533 Jul 18 20:48 arm-linux-as

2

username cvsd

331791

Jul 18 21:35 arm-linux-c++

1

username cvsd 1855723 Jul 18 20:48 arm-linux-c++filt

1

username cvsd

331290

Jul 18 21:35 arm-linux-cpp

2

username cvsd

331791

Jul 18 21:35 arm-linux-g++

2

username cvsd

330887

Jul 18 21:35 arm-linux-gcc

2

username cvsd

330887

Jul 18 21:35 arm-linux-gcc-3.4.3

1

username cvsd

16265

Jul 18 21:35 arm-linux-gccbug

1

username cvsd

102084

Jul 18 21:35 arm-linux-gcov

1

username cvsd 2373278 Jul 18 20:48 arm-linux-gprof

2

username cvsd 2622683 Jul 18 20:48 arm-linux-ld

2

username cvsd 1937609 Jul 18 20:48 arm-linux-nm

1

username cvsd 2454999 Jul 18 20:48 arm-linux-objcopy

1

username cvsd 2595563 Jul 18 20:48 arm-linux-objdump

2

username cvsd 1960209 Jul 18 20:48 arm-linux-ranlib

1

username cvsd

429743

Jul 18 20:48 arm-linux-readelf

1

username cvsd 1806673 Jul 18 20:48 arm-linux-size

1

username cvsd 1780595 Jul 18 20:48 arm-linux-strings

2

username cvsd 2454994 Jul 18 20:48 arm-linux-strip

1

username cvsd

14395

Jul 18 21:47 fix-embedded-paths

5.3.2Crosstool Embedded (Das U-Boot) Toolchain

The instructions above can be followed to create a toolchain suitable for cross-compiling Arm-Linux programs on a host machine. The needs for building the boot loader are a bit different, though. In particular, the ’glibc’ reference above refers very specifically to userspace ”C” and ”C++” libraries that defer much of their I/O to the Linux kernel itself through the use of system calls.

Under Das U-Boot, no such system calls exist. In order to support this, we need to build a Cross-compiler with a different set of switches. Thank- fully, the current crosstool distribution supports that as well through the use of a small library known as newlib from Red Hat.

The next couple of steps will do just that.

First of all, create a file named

crosstool-0.37/contrib/newlib/arm-elf-newlib-1.12.0.dat

and paste the following content into it.

TARGET=arm-elf

TARGET_CFLAGS="-O2"

BINUTILS_DIR=binutils-2.14

BINUTILS_URL=ftp://ftp.gnu.org/pub/gnu/binutils

NEWLIB_DIR=newlib-1.12.0

NEWLIB_URL=ftp://sources.redhat.com/pub/newlib

21 hr, 15 minutes on a 1GHz Athlon w/512MB of RAM

December 28, 2005

Revision 2.8

Page 17
Image 17
Sonic Alert 2.8 user manual TARGETCFLAGS=-O2