[Aboriginal] Using filesystem images on real hardware
rob at landley.net
Mon Jul 11 07:34:51 PDT 2011
On 07/10/2011 09:21 AM, Matthew J Fletcher wrote:
> On 10/07/11 08:34, David Seikel wrote:
>> On Sun, 10 Jul 2011 08:15:15 +0100 Matthew J Fletcher<amimjf at sky.com>
>>> how did you find that just these config options need to be set,
>>> looking at most linux kernel config files there are about 4000 lines
>>> in it. I guess most of those are defaults, do you just diff a default
>>> config file against a board specific one and see whats different ?
>>> then make semi intelligent guesses about if those changes are
>>> actually target specific or just the personal preference of the guy
>>> who created the kernel config for that board ?
>> That's called a miniconfig. Have a look at
>> sources/toys/miniconfig.sh for some details about those.
> Ok, i also looked the comments in the script and the docs at
> http://lwn.net/Articles/160497/ but i think i am missing a bit of
> documentation on how this works.
Did the FAQ help?
> For my board i have a patched 2.6.31 by freescale, it comes with a
> .config file
You'll want to either stick a tarball of the 2.6.31 in
"packages/alt-linux-0.tar.bz2" or just populate the package cache by
hand (put the extracted version at "build/packages/alt-linux" and
_don't_ have a tarball in packages so it won't think it's out of date
and try to update it).
Then export USE_UNSTABLE=linux when you do your build.
There are some sources/targets/alt-linux-*.patch patches, mostly
removing the need for "perl" from the build (2.6.25 added it because
peter anvin is crazy). If you don't want to patch it you can just set
HOST_EXTRA=qemu (either export it as an environment variable or set it
> So in the LWN article it says 'create a mini.config file', so i 'touch
> I then run 'make allnoconfig KCONFIG_ALLCONFIG=mini.config', my .config
> file is now 14k instead of 17k, but mini.config is still zero bytes.
That converts a miniconfig into a full .config the build can use, you
need to go the other way (which is what miniconfig.sh does, alas very
> Looking at the usage for miniconfig.sh "Usage: miniconfig.sh
> configfile". I do './miniconfig.sh mini.config', which gives me the
> following output
> .config mini.config differ: byte 1, line 1
> Insanity test failed: reversing blank line removal heuristic.
In theory, blank lines and comment lines shouldn't affect the output, so
it tries removing them.
Unfortunately, in current Linux kernels it DOES make a difference, which
is crazy but there you go. (It doesn't matter in the configs I'm using,
but it does in defconfig. I forget why. Make a miniconfig and see
which "#CONFIG_BLAH is not set" lines are still there. That's the ones
where something funky happens if you don't explicitly switch it off,
even though we started with allnoconfig.)
I've meant to look more closely into this for a while, but my todo list
runneth over. (I've gotta go to work now, actually.)
> Calculating mini.config...
>  0/0 lines 0 bytes 100%
> but my mini.config is still zero bytes.
Because you started with an empty file, it fed it into allnoconfig, and
then boiled it back down to the resulting miniconfig which was your
empty file back.
> anybody got a set of steps to follow for miniconfig.sh
Lemme know if the FAQ is insufficient, and if so what to fix.
More information about the Aboriginal