Gentoo Archives: gentoo-embedded

From: "Stanisław Raczyński" <sraczynski@××.pl>
To: gentoo-embedded@l.g.o
Subject: Re: [gentoo-embedded] Building a cross-compile environment for ARM
Date: Thu, 30 Mar 2006 13:49:36
Message-Id: 442BE1D2.1010009@op.pl
In Reply to: [gentoo-embedded] Building a cross-compile environment for ARM by Derick Swanepoel
1 Derick Swanepoel wrote:
2
3 >Hi,
4 >
5 >I'm busy building a cross-compile environment for an ARM (XScale) in an x86
6 >host environment, but I'm having trouble emerging packages like procps and
7 >gdb which require headers from /usr/include.
8 >
9 >
10 What do you need procps for? If you're using busybox, it already
11 contains ps, free, top and kill and it should be enough for most
12 embedded systems.
13
14 >I've built an armeb-softfloat-linux-uclibc cross toolchain with crossdev
15 >which can successfully compile uclibc, bash, baselayout, etc. and install
16 >in ROOT=/gentoo-arm. However, when I try to emerge something like procps,
17 >it fails to find curses.h and termcap.h. Where should the cross-compiler be
18 >looking for these headers?
19 >
20 >
21 Is ROOT the only variable you set? There are some other important vars,
22 like ARCH, CBUILD, CHOST, CTARGET. Many others are also useful while
23 cross-emerging.
24
25 >Another problem I have is that gawk (3.1.4-r4) fails to execute with:
26 >awk: can't resolve symbol '__fixdfsi'
27 >As far as I can determine, __fixdfsi is one of GCC's softfloat library routines.
28 >
29 >I would really like to know how the armeb-uclibc-softfloat stages (found in
30 >experimental/arm/embedded on various Gentoo mirrors) were built.
31 >
32 >
33 As far as I know, they use catalyst.
34
35 >Thanks,
36 >Derick
37 >
38 >
39 >
40 I am building small Embedded Gentoo systems for i686 and ARM920T
41 architectures and for that I wrote a little script called egg
42 (attached). Perhaps you will find it useful. To create such a system for
43 arm920t (baselayout+uclibc+busybox), I'd simply run:
44
45 # crossdev -t arm-unknown-linux-uclibc
46 # egg -l uclibc -a arm920t -o /home/gentoo-for-arm
47
48 Later, to add some packages (e.g. dropbear and ncurses) I'd write:
49
50 # egg -l uclibc -a arm920t -o /home/gentoo-for-arm -fn dropbear ncurses
51
52 And finally, when I'm satisfied with my rootfs, I can strip it off
53 unnecessary trash:
54
55 # egg -l uclibc -arm920t -o /home/gentoo-for-arm -fns
56
57 This is an extremely simple tool (e.g. you can't set USE flags for
58 individual packages), but still I find it quite sufficient for my work.
59 You can use it to generate a rootfs for an armeb architecture just by
60 adding it to parse_arch() function. If you do that, don't forget to send
61 me the updated version.
62
63 Hope you find it useful,
64 Stanislaw Raczynski

Attachments

File name MIME type
egg text/plain

Replies

Subject Author
Re: [gentoo-embedded] Building a cross-compile environment for ARM Derick Swanepoel <dswanepoel@×××××.com>