On Wed, 2008-10-29 at 20:07 +0100, Sam Ravnborg wrote: > On Tue, Oct 28, 2008 at 01:36:25PM +0000, Ian Campbell wrote: > > Architectures which have moved their includes to arch/<ARCH>/include > > now list the headers twice in the source listing used by "make > > cscope" and friends, causing those tools to list symbols twice. > > > > Skipping these files in the ALLSOURCE_ARCHS pass rather than removing > > the ALLINCLUDE_ARCHS pass preserves the semantics of the later. > > > > Signed-off-by: Ian Campbell <ijc@xxxxxxxxxxxxxx> > > Cc: Sam Ravnborg <sam@xxxxxxxxxxxx> > > Cc: linux-kbuild@xxxxxxxxxxxxxxx > > > > diff -r a613b893f5b5 Makefile > > --- a/Makefile Mon Oct 27 10:29:49 2008 +0000 > > +++ b/Makefile Tue Oct 28 13:33:04 2008 +0000 > > @@ -1435,7 +1435,8 @@ > > define find-sources > > ( for arch in $(ALLSOURCE_ARCHS) ; do \ > > find $(__srctree)arch/$${arch} $(RCS_FIND_IGNORE) \ > > - -name $1 -print; \ > > + -wholename $(__srctree)arch/$${arch}/include/asm -type d -prune \ > > + -o -name $1 -print; \ > > done ; \ > > find $(__srctree)security/selinux/include $(RCS_FIND_IGNORE) \ > > -name $1 -print; \ > > > > Hi Ian. > > I would much rather prefer to see a patch that > - support the platforms of arm and others How do you mean? $ ls arch/arm/include/ asm/ so it'll work as well for arm as it does for any other architecture. All this patch does is stop the ALLSOURCE_ARCH loop from covering files which are also picked up by the ALLINCLUDE_ARCH loop. Including those files twice is a regression from before the headers got moved. > - uses the fact that all arch have their header files moved > to arch/$ARCH/include > [Ignore the archs that are lacking behind] in that case you would simply also remove the : test -e $(__srctree)include/asm-$${arch} && \ find $(__srctree)include/asm-$${arch} $(RCS_FIND_IGNORE) \ -name $1 -print; \ from the ALLINCLUDE_ARCHS loop. > And if we could simplify this "find file" list on top of that it would be extra bonus. Unless you want to get rid of the distinction between ALLINCLUDE_ARCHS and ALLSOURCE_ARCHS I don't think it can get any simpler. If you did want to get rid of that distinction then it would simply be a case of removing the ALLINCLUDE_ARCHS loop and ignoring this patch. Ian. -- Ian Campbell Perhaps they will have to outlaw sending random lists of words. fee fie foe foo [sic] -- Larry Wall in <199710311916.LAA19760@xxxxxxxx> -- To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html