[PATCH] Allow `make O=<obj> {cscope,tags}` to work

From: George G. Davis
Date: Mon Jul 19 2004 - 12:19:58 EST


Greetings,

Here's a trivial fix to allow `make O=<obj> {cscope,tags}` to work:


# This is a BitKeeper generated diff -Nru style patch.
#
# ChangeSet
# 2004/07/19 12:49:14-04:00 gdavis@xxxxxxxxxxxxxxxxxxxxxxxxxxx
# Makefile:
# Allow `make O=<obj> {cscope,tags}` to work
#
# Makefile
# 2004/07/19 12:28:02-04:00 gdavis@xxxxxxxxxxxxxxxxxxxxxxxxxxx +9 -9
# Allow `make O=<obj> {cscope,tags}` to work
#
diff -Nru a/Makefile b/Makefile
--- a/Makefile 2004-07-19 13:00:49 -04:00
+++ b/Makefile 2004-07-19 13:00:49 -04:00
@@ -1009,26 +1009,26 @@
# ---------------------------------------------------------------------------

define all-sources
- ( find . $(RCS_FIND_IGNORE) \
+ ( find $(srctree) $(RCS_FIND_IGNORE) \
\( -name include -o -name arch \) -prune -o \
-name '*.[chS]' -print; \
- find arch/$(ARCH) $(RCS_FIND_IGNORE) \
+ find $(srctree)/arch/$(ARCH) $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print; \
- find security/selinux/include $(RCS_FIND_IGNORE) \
+ find $(srctree)/security/selinux/include $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print; \
- find include $(RCS_FIND_IGNORE) \
+ find $(srctree)/include $(RCS_FIND_IGNORE) \
\( -name config -o -name 'asm-*' \) -prune \
-o -name '*.[chS]' -print; \
- find include/asm-$(ARCH) $(RCS_FIND_IGNORE) \
+ find $(srctree)/include/asm-$(ARCH) $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print; \
- find include/asm-generic $(RCS_FIND_IGNORE) \
+ find $(srctree)/include/asm-generic $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print )
endef

-quiet_cmd_cscope-file = FILELST cscope.files
- cmd_cscope-file = $(all-sources) > cscope.files
+quiet_cmd_cscope-file = FILELST $(obj)/cscope.files
+ cmd_cscope-file = $(all-sources) > $(obj)/cscope.files

-quiet_cmd_cscope = MAKE cscope.out
+quiet_cmd_cscope = MAKE $(obj)/cscope.out
cmd_cscope = cscope -k -b -q

cscope: FORCE


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