[lkml]   [1996]   [Dec]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: source dependencies cleanup?

In, article <>,
"Peter T. Breuer" <> writes:
> > Not a major pain as the kernel takes a while to compile on this machine
> > anyway but I believe (after a quick perusal of the .depend files) that
> > mkdep is fast mainly because it skips stuff.
> Absolutely wrong (i.e. "that turns out not to be the case" :). It is

Sorry, but Linus' mkdep _does_ skip stuff.

Assume that a1.c and a2.c both include b.h which in turn includes c.h.

GCC -M output would be
a1.o: a1.c b.h c.h
a2.o: a1.c b.h c.h

Linus' mkdep instead depends on being executed on the heders too:
a1.o: a1.c b.h
a2.o: a1.c b.h
b.h: c.h
touch b.h

This all works out perfectly well. Well... almost. The big advantage of the
latter is that you scan b.h only once; gcc scans it twice. The big
disadvantage is that you can't keep your kernel sources on a readonly

It were not best that we should all think alike; it is the difference
of opinion that makes horse races.
Matthias Urlichs \ noris network GmbH / Xlink-POP Nürnberg
Schleiermacherstraße 12 \ Linux+Internet / EMail:
90491 Nürnberg (Germany) \ Consulting+Programming+Networking+etc'ing
PGP: 1024/4F578875 1B 89 E2 1C 43 EA 80 44 15 D2 29 CF C6 C7 E0 DE
Click <A HREF="">here</A>. 42

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