Re: Quick and dirty miniconfig howto, with feature suggestions.

From: Rob Landley
Date: Sat Nov 19 2005 - 22:44:46 EST

On Thursday 17 November 2005 06:29, Rob Landley wrote:
> --- What is a miniconfig?
> A new feature of 2.6.15 lets you use miniature configuration files, listing
> just the symbols you want to enable and letting the configurator enable any
> dependencies to give you a valid configuration.
> To make it work, create a mini.config file and run allnoconfig (to create
> a .config file with all unspecified symbols switched off) with the extra
> argument "KCONFIG_ALLCONFIG=mini.config".

And here's a shell script that will automatically create a mini.conf from a
standard .config file.

It does this via the simple expedient of trying to remove each line and seeing
which ones make any difference to the generated .config. (This means it runs
make allnoconfig about 1300 times. This is very very slow, so it displays a
progress indicator.)

To use the script, go into the kernel source directory, create your .config
file (via menuconfig or however), rename that .config file to something else
(like "myconfig"), then run the script like so:

./ myconfig

(Note you still have to be in the directory where the script can run "make
allnoconfig".) When it finishes, you should have a mini.conf containing the
minimal set of lines necessary to specify that configuration via
"make KCONFIG_ALLCONFIG=mini.config allnoconfig".

I'm sure there's a better way to do this, but this works now.


Description: application/shellscript