All of lore.kernel.org
 help / color / mirror / Atom feed
From: greg@kroah.com (Greg KH)
To: kernelnewbies@lists.kernelnewbies.org
Subject: Why each time of kernel compilation must be done completely?
Date: Wed, 19 Nov 2014 18:43:26 -0800	[thread overview]
Message-ID: <20141120024326.GA3518@kroah.com> (raw)
In-Reply-To: <80732.17e9b.149caf21a4d.Coremail.michaelbest002@126.com>

On Thu, Nov 20, 2014 at 10:05:04AM +0800, ??? wrote:
> Hi,
> 
> This problem has puzzled me for a long time. A normal C make file could parse
> the reliance and just regenerate the modified source file. But each time when I
> modified the kernel and recompile it, it does a complete compilation, no matter
> whether make mrproper is used or not. It's quite time consuming and
> inefficient.
> 
> So why kernel make file couldn't do what a normal C make file could do? Or
> maybe it could but I got something wrong? 

I think you are doing something wrong, unless you are changing a
configuration option, version of gcc, or are changing a .h file that all
files include.

What are you changing and doing that causes a full rebuild?  Can you
show us exactly?

> If a complete compilation is inevitable, how to make it faster? I only know the
> -jX option.

-jX is all you need.  You can use ccache if you are rebuilding the same
thing all the time, or distcc if you have other machines on your network
to take advantage of.

thanks,

greg k-h

  reply	other threads:[~2014-11-20  2:43 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-20  2:05 Why each time of kernel compilation must be done completely? 秦弋戈
2014-11-20  2:43 ` Greg KH [this message]
2014-11-20  3:23   ` Valdis.Kletnieks at vt.edu
2014-11-21  3:11   ` 秦弋戈

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20141120024326.GA3518@kroah.com \
    --to=greg@kroah.com \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.