ts-7000
[Top] [All Lists]

Re: [ts-7000] I built a 2.6 kernel; now what? :)

To:
Subject: Re: [ts-7000] I built a 2.6 kernel; now what? :)
From: Triffid Hunter <>
Date: Mon, 25 Jun 2007 01:31:35 +1000 (EST)
On Sun, 24 Jun 2007, Jeff Cunningham wrote:

> Triffid Hunter wrote:
>>
>> I made my own using gentoo - see
>> http://www.gentoo. org/proj/ en/base/embedded /cross-developme nt.xml
>> <http://www.gentoo.org/proj/en/base/embedded/cross-development.xml>
>>
>> The root filesystem is 20MB all up including busybox, glibc, dropbear,
>> nano and openntpd. I've removed all the development stuff like include
>> headers and kernel sources and package databases and library archives,
>> since with those included it's some 800MB!
>>
>> I've uploaded a few bits and pieces to
>> http://triffid. funkmunch. net/ts7250/
>> <http://triffid.funkmunch.net/ts7250/> if you want some shortcuts :)
>>
>> I developed it on an nfs mount then copied to flash - works great!
>>
>> At some stage I'll build a uclibc root and see which I like better. I
>> already know it'll be much smaller since I use uclibc for my ~1.6MB
>> initramfs, but haven't yet looked closely into the differences between
>> glibc and uclibc.
>>
> This helps a great deal, Triffid.
>
> This is starting to make sense. One thing I don't quite understand: can
> I use the glibc I built for the cross compilation toolchain for the one
> that ends up in the root file system on my ts7200? Or do I have to build
> another one? Is it just an issue of size? 20MB seems quite reasonable to
> me, as I've got a 512M CF to work from.

I copied all the .so* files from /usr/arm-unknown-linux-gnu/{,usr/}lib/ to 
my buildroot and image. Doesn't affect linking which uses the files 
crossdev installs in /usr/$TARGET, but they need to be available to 
userspace apps once booted.

I have two dirs: ~/armroot which is the buildroot at which I point armerge 
(gets headers and archives and all sorts of cruft like that installed), 
and ~/armimage which contains *only* the necessary binaries and configs - 
this is what I nfs-mounted for testing, then copied to flash. You could 
probably use the /usr/$TARGET which crossdev creates for you as your 
buildroot to save lots of duplicate files.

> Were you able to use Gentoo's crossdev to build your toolchain? I spent
> half a day before giving up. I could not find a combination of
> components that would build all the way. I left off at
>
> crossdev -t arm --b 2.17 --g 4.1.1 --k 2.6.17 --l 2.2
>
> which successfully built binutils, gcc but failed to build glibc (I had
> worked my way down to 2.2 through a sequence of time-consuming failures
> before giving up). If you succeeded with crossdev, what command set worked?

crossdev -t arm-unknown-linux-gnu worked for me. 2nd stage gcc failed 
first time around, but emerge --resume fixed it. crossdev chose 
binutils-2.17, gcc-4.1.2, glibc-2.5-r3 and linux-headers-2.6.21 for me all 
by itself.

Looks like you didn't quite read the help closely enough:

  ~ # crossdev
  Usage: crossdev [options] --target TARGET
  ...
  Target (-t):  takes the form: ARCH-VENDOR-OS-LIBC
    Run 'crossdev -t help' for examples

  ~ # crossdev -t help
  Supported Architectures:
  ...
  - arm / armeb
  ...
  Supported C Libraries:
  - glibc (gnu)
  ...
  - uclibc
  ...
  Softfloat toolchains:
    Include 'softfloat' in the 'vendor' field
    e.g. armeb-softfloat-linux-uclibc  powerpc-booya_softfloat-linux-gnu

so -t arm wouldn't give you a vendor, os or libc which would get the 
toolchain rather confused. Your host system should be i686-pc-linux-gnu or 
similar for example. Use arm-unknown-linux-uclibc (instead of -gnu) for a 
uclibc toolchain.

According to http://wiki.debian.org/ArmEabiPort , 
arm-unknown-linux-gnueabi should create a toolchain that uses some new 
abi. Appariently it should be faster and do a few things better. I plan to 
try this shortly. My kernel already has support for it, but I need a new 
toolchain that supports it too. If you beat me to it, tell us how you go.



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ts-7000/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/ts-7000/join
    (Yahoo! ID required)

<*> To change settings via email:
     
    

<*> To unsubscribe from this group, send an email to:
    

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU