Recompiling Kernel

Recompiling Kernel

Post by Tom Alsber » Sun, 23 May 1999 04:00:00



  Hi there, I noticed that many answers to my questions require to recompile
my kernel, and also I am curious about working with Linux's source, so, can
anyone guide me through the steps of what files to edit, compiling the
kernel, and bringing to use that kernel I compiled? is there a makefile for
the kernel? where is the kernel source located? and something I looked for,
where is the source of all the commands in the bin/ and sbin/ directories? I
would really like to begin getting involved with Linux's source and
programming for Linux, I know C++ for 4 years (even forgot some of it
already ;-), but until now I programmed only for MS-DOS and MS-Windows...
please e-mail me and the group everything that can help me newbie-for-Linux.

  Any answer and guiding will really be appreciated,

  Tom Alsberg (Zoopee)

 
 
 

Recompiling Kernel

Post by Jens Webe » Sun, 23 May 1999 04:00:00



>   Hi there, I noticed that many answers to my questions require to recompile
> my kernel, and also I am curious about working with Linux's source, so, can
> anyone guide me through the steps of what files to edit, compiling the
> kernel, and bringing to use that kernel I compiled? is there a makefile for
> the kernel? where is the kernel source located? and something I looked for,
> where is the source of all the commands in the bin/ and sbin/ directories?

Well on my SuSE 6.2 Distribution the Kernel source is located in
/usr/src/linux
There IS a makefile, which you should use to compile the kernel !!
The Options are:
make menuconfig <-- puts you into a comfortable configurationmenu in
textmode.
                    there may be other config-menus, e.g. for X, but i
recommend
                    this option.
make clean      <-- clean up after config.
make dep        <-- makes dependencies
make zlilo      <-- compiles the kernel and install it within lilo
(Linux Loader)

Kernel too big ?!  <-- try to use modules !! (my kernel is too big too)

make bzlilo     <-- compiles a BIG kernel an install it within lilo.

There are a couple of other options such as make zImage, make bzImage
(for BIG Kernel). The best way is to first read the Docu, should be
located in
(/usr/src/linux/)Documentation !! This sould also be done to get a
proper working
kernel !!

These are my experiences with SuSE Linux but other Distributions should
behave
similar (hope so).

Jens

Quote:> I
> would really like to begin getting involved with Linux's source and
> programming for Linux, I know C++ for 4 years (even forgot some of it
> already ;-), but until now I programmed only for MS-DOS and MS-Windows...
> please e-mail me and the group everything that can help me newbie-for-Linux.

>   Any answer and guiding will really be appreciated,

>   Tom Alsberg (Zoopee)

--

to reply, please remove ~~~ from the above e-mail adress

 
 
 

Recompiling Kernel

Post by Gergo Bara » Sun, 23 May 1999 04:00:00



>  Hi there, I noticed that many answers to my questions require to recompile
>my kernel, and also I am curious about working with Linux's source, so, can
>anyone guide me through the steps of what files to edit,

You don't need to edit any files manually.

Quote:>compiling the
>kernel, and bringing to use that kernel I compiled? is there a makefile for
>the kernel? where is the kernel source located?

Consult the Kernel HOWTO. Generally, it's not a bad idea to bookmark
your local Linux Documentation Project Mirror.

Quote:>and something I looked for,
>where is the source of all the commands in the bin/ and sbin/ directories?

Many of them are in the GNU fileutils package, I think. Search
http://freshmeat.net (don't forget to use a mirror).

Quote:>I
>would really like to begin getting involved with Linux's source and
>programming for Linux, I know C++ for 4 years (even forgot some of it
>already ;-), but until now I programmed only for MS-DOS and MS-Windows...

The actual development of the kernel is coordinated in mailing lists, I
think. And Linux is written in C, so you'll have to learn that if you
want to be of assistance.

Gergo

--
Beware of the Turing Tar-pit in which everything is possible but
nothing of interest is easy.

GU d- s:+ a--- C++>$ UL+++ P>++ L+++ E>++ W+ N++ o? K- w--- !O !M !V
PS+ PE+ Y+ PGP+ t* 5+ X- R>+ tv++ b+>+++ DI+ D+ G>++ e* h! !r !y+

 
 
 

Recompiling Kernel

Post by mjmy.. » Mon, 24 May 1999 04:00:00



>   Hi there, I noticed that many answers to my questions require to recompile
> my kernel, and also I am curious about working with Linux's source, so, can
> anyone guide me through the steps of what files to edit, compiling the
> kernel, and bringing to use that kernel I compiled? is there a makefile for
> the kernel? where is the kernel source located?

Probably depends on your distribution (I only know Red Hat). Try
/usr/src/linux/   Depending on the dist, it may not be installed by
default.

From the source directoy:

make config  (or make xconfig  or  make menuconfig for easy setup).
make dep
make clean
make zImage  (there are several alternatives, but this is the most
common)

Image will be in [sourcedir]/arch/i386/boot/

Read the FAQ:

   http://lifted.rapiddata.com/ldp/HOWTO/Kernel-HOWTO.html#toc1

 
 
 

Recompiling Kernel

Post by Pravee » Tue, 25 May 1999 04:00:00



>   Hi there, I noticed that many answers to my questions require to recompile
> my kernel, and also I am curious about working with Linux's source, so, can
> anyone guide me through the steps of what files to edit, compiling the
> kernel, and bringing to use that kernel I compiled? is there a makefile for
> the kernel? where is the kernel source located? and something I looked for,
> where is the source of all the commands in the bin/ and sbin/ directories? I
> would really like to begin getting involved with Linux's source and
> programming for Linux, I know C++ for 4 years (even forgot some of it
> already ;-), but until now I programmed only for MS-DOS and MS-Windows...
> please e-mail me and the group everything that can help me newbie-for-Linux.

>   Any answer and guiding will really be appreciated,

>   Tom Alsberg (Zoopee)

If you would like to browse through the linux source, here is a good
place:
http://lxr.linux.no/source/
 
 
 

1. need to recompile ftape: recompile kernel too?

I'm trying to get ftape to work, and after upgrading my kernel to
2.0.0 on my Red Hat system I noticed the tape controller hex address
is wrong. I corrected the makefile in
/usr/src/linux/drivers/char/ftape so now I need to re-compile. I have
ftape setup as a loadable module.

The main question is do I need to recompile the whole kernel + modules
or should I just recompile ftape? Can I just run 'make modules' then
'make modules_install' and have it work? Or should I just run make in
/usr/src/linux/drivers/char/ftape and move ftape.o to
/lib/modules/2.0.0?

Any advice or insight is appreciated.
--

David

+--------------------------------------------------------------------+

| Mechanical Engineering Senior                                      |
| Mississippi State University             OS/2 and Linux user       |
|                                                                    |
|        "I'd explain it, but there's a lot of math." -- Calvin.     |
|                                                                    |
+------------- http://www2.msstate.edu/~dmi1/index.html -------------+

2. An interesting DNS problem

3. recompiled kernel, the new kernel does not boot

4. Help: MSDOS File system permissions.

5. After recompiling kernel with PPP support, pppd says the kernel has no PPP support!

6. Linux Network Newbie

7. Kernel Panic with recompiled kernel

8. route add network gives "Network not found"

9. Kernel Panic after booting recompiled kernel

10. Help: Trouble recompiling kernel, won't boot from new Kernel

11. ReCompiling Kernel 1.2.11

12. Any performance improvement by recompiling kernel?

13. Problems recompiling kernel