Makefile: fix wrong dirs when making cscope
PATCH RESEND 1/1 Makefile: fix wrong dirs when making cscope
Hi, Sam! Is this one OK for you?
This patch fixed the following errors when doing "make cscope" and "make cscope ARCH=um".
FILELST cscope.files
find: arch/i386: No such file or directory
MAKE cscope.out
FILELST cscope.files
find: include/asm-i386: No such file or directory
MAKE cscope.out
--- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Makefile +2 -1
@@ -1309,6 +1309,7 @@ ALLINCLUDE_ARCHS := $(ARCH) $(SUBARCH) else ALLINCLUDE_ARCHS := $(SRCARCH) endif +ALLINCLUDE_ARCHS := $(shell echo $(ALLINCLUDE_ARCHS)|sed -e "s/i386/x86/") else #Allow user to specify only ALLSOURCE_PATHS on the command line, keeping existing behavour. ALLINCLUDE_ARCHS := $(ALLSOURCE_ARCHS)
@@ -1318,7 +1319,7 @@ endif ifeq ($(ARCH), $(SRCARCH)) ALLSOURCE_ARCHS := $(ARCH) else -ALLSOURCE_ARCHS := $(ARCH) $(SRCARCH) +ALLSOURCE_ARCHS := $(shell echo $(ARCH) $(SRCARCH)|sed -e "s/i386/x86/") endif define find-sources
Hi WANG.
I ended up adding the following patch.
It fixes both x86_64 and i386 and is simpler. Plus I included the ncscope.out thing in the same patch.
Sam
commit 5683c81430f9cf2a2eaf71ce93291f00b528b6c4
Author: WANG Cong <[email protected]> Date: Thu Nov 8 17:22:11 2007 +0800
kbuild: fix cscope so it does not emit warnings
This patch fixed the following errors when doing "make cscope" and "make cscope ARCH=um".
FILELST cscope.files
find: arch/i386: No such file or directory
MAKE cscope.out
FILELST cscope.files
find: include/asm-i386: No such file or directory
MAKE cscope.out
In addition it teach kbuild to delete ncscope.out at mrproper
Makefile +3 -8
@@ -1086,7 +1086,7 @@ MRPROPER_DIRS += include/config include2 usr/include MRPROPER_FILES += .config .config.old include/asm .version .old_version \ include/linux/autoconf.h include/linux/version.h \ include/linux/utsrelease.h \ - Module.symvers tags TAGS cscope* + Module.symvers tags TAGS *cscope* # clean - Delete most, but leave enough to build external modules #
@@ -1318,7 +1318,7 @@ endif ifeq ($(ALLSOURCE_ARCHS),) ifeq ($(ARCH),um) -ALLINCLUDE_ARCHS := $(ARCH) $(SUBARCH) +ALLINCLUDE_ARCHS := $(SRCARCH) $(SUBARCH) else ALLINCLUDE_ARCHS := $(SRCARCH) endif
@@ -1327,12 +1327,7 @@ else ALLINCLUDE_ARCHS := $(ALLSOURCE_ARCHS) endif -# Take care of arch/x86 -ifeq ($(ARCH), $(SRCARCH)) -ALLSOURCE_ARCHS := $(ARCH) -else -ALLSOURCE_ARCHS := $(ARCH) $(SRCARCH) -endif +ALLSOURCE_ARCHS := $(SRCARCH) define find-sources ( for arch in $(ALLSOURCE_ARCHS) ; do \