LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 08-05-2010, 12:28 AM   #1
zeus
LQ Newbie
 
Registered: Jul 2010
Posts: 3

Rep: Reputation: 0
How to recompile kernel


I am trying some changes to the kernel code. To test them out I have to recompile the whole kernel with the $make command. Since I have not touched the major part of the kernel including the device drivers is there any way to only compile what I have changed and avoid rebuild all the modules every time.
 
Old 08-05-2010, 12:34 AM   #2
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
simple http://alien.slackbook.org/dokuwiki/doku.php?id=linux:kernelbuilding&s[]=kernel&s[]=compile
 
Old 08-05-2010, 12:45 AM   #3
zeus
LQ Newbie
 
Registered: Jul 2010
Posts: 3

Original Poster
Rep: Reputation: 0
Smile

To be more clear I dont want to recompile all the kernel modules every time. I could not find the information that I was looking for on the above website.

$make should just compile what has changed and not recompile all the kernel modules - which takes a lot of time.
 
Old 08-05-2010, 05:04 AM   #4
Suresh Maniyath
Member
 
Registered: Feb 2009
Location: India
Distribution: Fedora, Ubuntu
Posts: 37

Rep: Reputation: 19
Wink compiler cache

I am not sure whether you are looking for a compiler cache, you can think about using "ccache" available here "http://ccache.samba.org/"

Regards,
Suresh Maniyath
 
Old 08-05-2010, 11:14 PM   #5
zeus
LQ Newbie
 
Registered: Jul 2010
Posts: 3

Original Poster
Rep: Reputation: 0
problem fixed. make handles it automatically. just dont do make clean or make distclean. I dont know whether there are any side effects of not running make clean
 
Old 08-06-2010, 08:47 AM   #6
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
if you have a kernel that has been configured and built with modules. This happens with the make command . later you can run make xconfig or make menuconfig select the new modules you want built. then do make modules. always back up your /lib/modules/uname -r
make clean does that cleans your built modules then you will have to recompile them again if needed.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Kernel Panic in 64bit Arch Linux after Kernel Recompile: 2.6.35-rc3 jackerybakery Linux - General 3 06-16-2010 10:21 AM
Kernel recompile, LILO warning and Kernel-panic Tux-Slack Slackware 26 02-26-2008 05:15 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 11:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration