uArch

Ed W lists at wildgooses.com
Wed Apr 23 16:44:10 UTC 2008


Denys Vlasenko wrote:
> On Wednesday 23 April 2008 15:35, Ed W wrote:
>   
>> I guess you have tried gentoo before embarking down this route?  You can 
>> drop out a basic bootable image starting at about 5MB and go up from 
>> there.  Simple to build binary packages and merge them using qmerge.  
>> Build binary images for the architecture of your choice (although to be 
>> fair cross compiling for non native architectures adds some extra steps 
>> which are somewhat complicated).  Use uclibc/mdev/udev or whatever takes 
>> your fancy...
>>     
>
> Sounds surprisingly sane.
>
> Maybe it even uses something less arcane than init-with-runlevels-
> and-tons-of-scripts-in-/etc?
>   


I don't really know arch-linux so I don't know if you are being ironic 
about that or gentoo?

However, I can dip into the buildroot and turn on or off services using 
(from my build script):

    # Don't start unneeded and unavailable services
    rc-config delete keymaps boot
    rc-config delete consolefont boot

    #setup some default services
    rc-config add dropbear default
    rc-config add net.eth0 default

Building a root file system is easily scriptable, but the first few 
lines of my build script look like:

    export PROJECT=base1
    export EMBEDDED_ROOT=/var/embedded
    export ROOT=/var/embedded/builds/${PROJECT}
    export PORTAGE_CONFIGROOT=/var/embedded/portage
    emerge -vK baselayout
    emerge -vK uclibc busybox

Roughly speaking you run this under a chroot which matches your target 
environment (eg I use an x586 environment although the host is running 
AMD64), then this builds you a simple (small) base filesystem which will 
do not much more than boot and give you a busybox shell.  Customise or 
add software from there. eg:

    emerge -avK dropbear postfix dovecot madwifi-ng wpa_supplicant
    hostapd openntpd dnsmasq e2fsprogs ppp l7-protocols iptables firehol
    gpsd


See the Tiny Gentoo entry on the gentoo wiki for a leg up, but you can 
do much better than that and I could be badgered to add my build scripts 
somewhere if people were interested.  Takes a couple of mins only to 
build a new base layout (and mine is now about 120MB of stuff using 
mdev, busybox and uclibc! )

All the best

Ed W

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.busybox.net/pipermail/uclibc/attachments/20080423/ec5095d3/attachment-0002.htm 


More information about the uClibc mailing list