Operating System - Linux
1821244 Members
2756 Online
109632 Solutions
New Discussion

How to build kernel on Linux 6.X?

 
Worapoj P.
Regular Advisor

How to build kernel on Linux 6.X?

Dear all expertise ,
how to re-build Linux's kernel , even I added some driver?

Thanks in advance for you helps,
Worapoj.
For LOVE For Honor For Mankind
1 REPLY 1
Stuart Browne
Honored Contributor

Re: How to build kernel on Linux 6.X?

I take it you mean RedHat 6.x?

If you've installed the source, you should be able to read the instructions that come with it.

Usually the source will be installed in /usr/src/linux-.

Once in there, you need to do the following (from the 'README'):

make config (or menuconfig, or xconfig)
make dep
make bzImage (or 'lilo')
make modules
make modules_install

Depending on whether you made an Image or used 'lilo' will depend on what is required to be done to put the kernel in place.

You will also need to play with 'mkinitrd' if you didn't compile the root disk controller's drivers into the kernel (ie. made it a loadable module).

'man mkinitrd' is your friend.
One long-haired git at your service...