Linux from scratch

Silviu Popescu silviupopescu1990 at gmail.com
Tue Apr 9 07:08:40 EDT 2013


On Tue, Apr 9, 2013 at 12:49 PM, Alexandru Juncu <alexj at rosedu.org> wrote:
> Hello!
>
> I am not a professional kernel developer but I do like learning how
> things work..especially operating systems like linux. I know the basis
> stuff  about the linux kernel (enough to write a very simple kernel
> module).  But I wanted to learn how things like a simple scheduler or
> a memory manager would work.
>
> Only reading the current kernel code is sometimes difficult because
> all the layers of abstraction implemented in order to make Linux code
> scale.  So I was thinking taking a much much older version of the
> kernel and starting to analyze it. Something like...v0.01. Seems like
> I'm on a good track since sched.c in v0.01 has 250 lines while shed.h
> in the current kernel has 1200 :P.
>
> But I couldn't get v0.01 to compile and I've search the Internet and
> found that it needs a _lot_ of hacking to get it to work. So I moved
> to try 1.0 which seems to have all of the basic features implemented
> yet simple enough  to understand. But I am still  having trouble
> compiling (having trouble with header files...). Although I could just
> read the code and try to figure out what it does, I would like to be
> able to modify it and compile and run it.
>
> In order to avoid useless trial and error, I wanted to ask other
> people that maybe did this: What is the oldest kernel version that can
> be compiled on a current system and then pun on a virtual machine like
> qemu-kvm or vmware?
>
> On a side note, I did look into the "Linux from scratch" documentation
> project, but that seems to tell you how to build a distribution, not a
> kernel.

I remember someone on kernel-newbies trying to do the same thing some
while ago[1].
Although the thread does not provide the solution it highlights some
of the obstacles you might face.
I also found a small blog post[2] about this. But the article is from
2007, and you're going for something way older than 2.4 so probably a
plethora of errors are coming your way.
Hope this helps and good luck.

[1] http://thread.gmane.org/gmane.linux.kernel.kernelnewbies/42878/focus=42884
[2] https://divyad.wordpress.com/2007/04/28/compiling-older-linux-kernels-preparations/

--
Silviu Popescu



More information about the Kernelnewbies mailing list