[Aboriginal] miniconfig-busybox

James McMechan james_mcmechan at hotmail.com
Thu Dec 1 12:43:10 PST 2011


> > I saw David Seikel's comments about still being interested in trim-config
> > Here is how I use mini-config with busybox, it is not hard
> > though I have not yet gotten the auto build stuff to include the aboriginal
> > tarball and the package directory in my initramfs
>
> There was an initramfs bug recent-ish-ly, are you using a version after
> http://landley.net/hg/aboriginal/rev/1366 ?

I was using Aboriginal-1.1.0 but am having a few problems
I seem to remember it working fine with 1.0.1, 1.0.0 and 0.9.11
now for some reason the patch command is failing, I will need to double
check the config file for busybox it may have a new knob in config somewhere

> > --- busybox.orig 2011-11-27 05:41:26.000000000 -0800
> > +++ busybox.build 2011-11-27 16:19:20.000000000 -0800
> > @@ -5,7 +5,8 @@
> > # Build busybox
> >
> > #make allyesconfig KCONFIG_ALLCONFIG="${SOURCES}/trimconfig-busybox" &&
> > -make defconfig &&
> > +#make defconfig &&
> > +make allnoconfig KCONFIG_ALLCONFIG="${SOURCES}/mini-busybox" &&
>
> I need to provide a way to select this, do a defconfig if no busybox
> config is provided, otherwise use that. Probably some kind of config
> setting.

well there is the classic method to try all three, there are prettier layouts though
done=0
[ $done -eq 0 -a -e "${SOURCES}/mini-busybox" ] && make allnoconfig KCONFIG_ALLCONFIG="${SOURCES}/mini-busybox" && done = 1
[ $done -eq 0 -a -e "${SOURCES}/trim-busybox" ] && make allyesconfig KCONFIG_ALLCONFIG="${SOURCES}/trim-busybox" && done = 1
[ $done -eq 0 ] && make  defconfig && done = 1
[ $done -ne 0 ] && \

> I'm also back to working on toybox, which means testing toybox, which
> means getting toybox and busybox to install alongside each other and
> gradually reduce the number of busybox commands I'm using.

Personally, I like building up from the bottom, rather than trying to trim
the fat from the top...

On a side note, I noticed busybox defconfig even has a webserver so
you could add your own private package mirror to dev-environment.sh

> I'm not inflicting toybox on aboriginal's default configuration any time
> soon, but I personally need the option.
>
> > cp .config "$WORK"/config-busybox &&
> > LDFLAGS="$LDFLAGS $STATIC_FLAGS" make -j $CPUS $VERBOSITY $DO_CROSS &&
> > make busybox.links || dienow
> >
> > I was adding very little to config
> >
> > export NO_CPLUSPLUS=1
> > export SYSIMAGE_TYPE=initramfs
> >
> > My preference is for mini-config rather than trim-config so I can turn on just what I want
>
> I admit the trimconfig was a bit of a hack; trying to use defconfig but
> it didn't work. And now busybox defconfig is back to not working
> because the UBI stuff doesn't build on ubuntu 11.10.

I like miniconfig primarily because of the lack of changes, if some later version needs a extra
config option the option is ignored by previous versions, the base stuff in busybox mostly
just works.  It is the advanced stuff and new options that usually give me grief.

> > I am using a ~98 line mini-config which needs few changes between busybox versions
> > It is possible that a few more options can be turned off I would like to convert the
> > initramfs to bz2 and drop gzip.
> > Without genext2fs it appears it doesn't need TAR_OLDGNU_COMPATIBILITY
> > apparently that program's build environment was very very old.
>
> I need to write my own genext2fs. Now that I'm back working on toybox,
> I may manage that eventually...

I usually just use initramfs I only need ~2 device files to boot
for testing so the setup for cpio is quite easy even by hand.
mdev from busybox takes care of the rest of the device files later.
The new DEVTMPFS in the kernel might make even that unneeded
I have not tested without /dev/console yet though...

> > #needed for od -t option in busybox build
> > CONFIG_DESKTOP=y
>
> I've argued with Denys about that. CONFIG_DESKTOP is not well defined,
> there's no clear rule for what it does and doesn't do.
>
> This config is enough to build aboriginal linux itself, with this in
> hostconfig?

It was working earlier, last tested about 1.0.2, I need to check with the new
version.

> A) Does that include running the ./download.sh stage?

download.sh does not use the host tools path and breaks at the moment
I did not set wget or ifconfig in busybox nor test download.sh

> B) Have you tried lfs-bootstrap.hdc with this?

I have not been checking LFS I was looking more like tinycore linux
and most of my testing has been under user-mode-linux since I had
that ready to run already

When testing I repeatedly run the same kernel with different initramfs
or recompile the kernel repeatedly with the same initramfs they are
conceptually separate in my mind so I almost always work on one
or the other alternately.

I noted that the command I have been testing with does not seem to
work for host tools like might be hoped.
STAGE_NAME=host-tools more/test.sh i686 build_section busybox
it gets all unhappy about pod2text pod2man & pod2html, but

leaves a statically linked busybox binary in host-tools-i686

It would be somewhat easier if host acted like a real target.
The current special case logic seem to get in my way as much as help
when trying repeated host-tools setups.

It was also quite awkward to use the default simple-cross-compiler.sh,
when I was having trouble with uClibc or linux-headers as it kept
rebuilding binutils & gcc. I quickly commented them out, but it would
seem that having each package saved in the build directory not just
the assembled meta-packages would be nice.
For example busybox-host.tbz busybox-i686.tbz uClibc-host.tbz

My opinion is when a system is working well simple things are
simple, and hard things are straightforward. I almost seems like
too much has been spent here make the hard parts easy and the
simpler parts have gotten more complex as a result.

 		 	   		  


More information about the Aboriginal mailing list