[BusyBox] autoconf

Rob Landley rob at landley.net
Wed Oct 6 07:18:16 UTC 2004


On Tuesday 05 October 2004 23:10, Peter Willis wrote:

> You are right, in part, but the intended target of busybox is usually
> not the same as the machine it is being built on. Autoconf is great for
> configuring a package to the current system's settings, but the
> destination system may be greatly different, and one would simply have
> to re-specify configuration options over and over for different systems,
> whereas with kbuild simply making a .config file saves all those
> settings.

Or running a properly specified ./configure line with the appropriate 
--overrrides saves those settings too.  (You don't _have_ to rerun 
./configure on every build if you don't want to...)

? Not to mention the fact that there are probably hundreds of
> options for busybox now, which would if anything merely make for an
> incredibly long ./configure line, right?

As opposed to an incredibly long .config file?  There's a difference?

It's not incredibly long if it gets some of them right.  And half of what it's 
doing is testing the headers you're going to compile against for things like 
this abomination from libbb/loop.c:

/* Grumble...  The 2.6.x kernel breaks asm/posix_types.h
 * so we get to try and cope as best we can... */
#include <linux/version.h>
#include <asm/posix_types.h>
#if LINUX_VERSION_CODE >= 132608
#define __bb_kernel_dev_t   __kernel_old_dev_t
#elif LINUX_VERSION_CODE >= 0x20600
#define __bb_kernel_dev_t   __kernel_dev_t
#else
#define __bb_kernel_dev_t   unsigned short
#endif

If you properly specify your cross-compiler, which has the right headers for 
the target, then it can tell "oh, the environment I'm going to compile 
against has long file support" and 8 zillion other little things.

> Personally I think everyone's time would be better spent fixing bugs and
> adding functionality than creating a hybrid configuration tool... But
> thats just me.

You don't get to say how other people spend their time on a collaborative 
volunteer project.  You really don't.  Sometimes volunteers want to focus on 
something other than what would be most convenient for you.  Complaining 
about it just makes them point and laugh, which I will now do.

Done.

I've complained about that snippet in loop.c before.  That's something I would 
spend my own time to fix (well, next week anyway when I HAVE time to spend) 
if I had a way forward.  Making autoconf autodetect this thing would be worth 
me overcoming my personal dislike for autoconf and learning how to use it 
just enough to make that particular irritation go away.  Once autoconf was 
being used for busybox, anyway...

And now I REALLY need to pay attention to Linucon, not this mailing list. :)

Rob
-- 
www.linucon.org: Linux Expo and Science Fiction Convention
October 8-10, 2004 in Austin Texas.  (I'm the con chair.)




More information about the busybox mailing list