lkml.org 
[lkml]   [2002]   [Sep]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: clean before or after dep?
On Sun, Sep 08, 2002 at 02:09:00PM -0400, D. Hugh Redelmeier wrote:
> What are the ordering constraints on mrproper, clean, dep, and
> *config? I'd like to characterise all sequences that properly prepare
> for a kernel build.
Lets go through the targets in question, and their purpose:
mrproper:
mrproper removes all files generated during the build process. This
includes the final kernel, the current configuration, firmware for
drivers, host-progs used during compilation, buildversion,
the include/asm link and a few more files.
mrproper is the right choice when you are going to build a new kernel
or something weird happend during the build process.
make mrproper are needed from time to time with the 2.4 kernel, when the
kernel build system gets 'confused'.
When executing mrproper, the first step is actually a clean as described below.

clean:
Clean removes all intermidiate files generated during the build process.
make clean will force all SRC to be build because all the .o files are
deleted.
[Checking arch/i386/Makefile + arch/i386/boot/Makefile]
make clean delete the final bzImage as well, which kinf of suprised me,
I did expect that mrproper were needed to do that.

dep:
In the 2.4 kernel make dep is used to record all the dependencies.
In the 2.5 kernel it's used for much less than in 2.4 kernel.
==>You need someone more familiar than me to comment on that.

*config:
As you probarly know it is used to build the .config.
To my best knowledge make dep, make clean does not have any influence.
But make mrproper will delete the .config file.

> What these targets do, according to README:
>
> mrproper: removes stale .o files and dependencies lying around
> clean: ? seems to remove files built by the build process
> *config: configure the kernel [build a .config]
> dep: set up dependencies
>
> The normal sequence seems to be:
> mrproper && *config && dep && build
> I'm not sure where clean comes in this sequence. mrproper includes
> clean, so this sequence will do it once. Is it needed somewhere after
> the *config too?
No, if executed before that should do it.

> - is it safe to do an mrproper after a *config? In other words, does
> mrproper affect/damage/undo anything done by *config?
Yes, .config is deleted.

> - is it necessary to do a clean after a *config? (README suggests no;
> many things in Documentation suggest yes.)
> One reason might be that dep requires this -- is this the case?
> <http://www.van-dijk.net/linuxkernel/200223/0432.html> suggests yes.
> Experience suggests no, at least until very recently.
> Or is there some other way in which dep now requires that
> it be preceded by a clean, perhaps after a failed build?
With the 2.5 kernel, if make clean or make mrproper is ever _required_
I would say you had triggered an error in the kernel build system.

> - theory: a clean should be done after a failing build so that
> a subsequent build won't use the results of the failing build.
Should not be needed with the build system in the 2.5 kernel.

Sam
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:28    [W:0.091 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site