All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xen/build: Fix `make cscope` rune
@ 2021-12-16  9:20 Andrew Cooper
  2021-12-16 14:00 ` Jan Beulich
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Andrew Cooper @ 2021-12-16  9:20 UTC (permalink / raw)
  To: Xen-devel
  Cc: Andrew Cooper, Anthony PERARD, Jan Beulich, Roger Pau Monné,
	Wei Liu, Stefano Stabellini, Julien Grall, Volodymyr Babchuk,
	Bertrand Marquis

There are two problems, both in the all_sources definition.

First, everything in arch/*/include gets double hits with cscope queries,
because they end up getting listed twice in cscope.files.

Drop the first `find` rune of the three, because it's redundant with the third
rune following c/s 725381a5eab3 ("xen: move include/asm-* to
arch/*/include/asm").

Second, and this way for a long time:

  $ make cscope
  ( find arch/x86/include -name '*.h' -print; find include -name '*.h' -print;
  find xsm arch/x86 common drivers lib test -name '*.[chS]' -print ) >
  cscope.files
  cscope -k -b -q
  cscope: cannot find file arch/x86/efi/efi.h
  cscope: cannot find file arch/x86/efi/ebmalloc.c
  cscope: cannot find file arch/x86/efi/compat.c
  cscope: cannot find file arch/x86/efi/pe.c
  cscope: cannot find file arch/x86/efi/boot.c
  cscope: cannot find file arch/x86/efi/runtime.c

This is caused by these being symlinks to common/efi.  Restrict all find runes
to `-type f` to skip symlinks, because common/efi/*.c are already listed.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
CC: Anthony PERARD <anthony.perard@citrix.com>
CC: Jan Beulich <JBeulich@suse.com>
CC: Roger Pau Monné <roger.pau@citrix.com>
CC: Wei Liu <wl@xen.org>
CC: Stefano Stabellini <sstabellini@kernel.org>
CC: Julien Grall <julien@xen.org>
CC: Volodymyr Babchuk <Volodymyr_Babchuk@epam.com>
CC: Bertrand Marquis <bertrand.marquis@arm.com>

Anthony: I looked through the remainder of your build series and I cant spot
any edits to all_sources.  Apologies if I missed it.
---
 xen/Makefile | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/xen/Makefile b/xen/Makefile
index 2ad7da7ad67b..dc6bdc44c7a2 100644
--- a/xen/Makefile
+++ b/xen/Makefile
@@ -468,9 +468,8 @@ arch/$(TARGET_ARCH)/include/asm/asm-offsets.h: asm-offsets.s
 
 SUBDIRS = xsm arch/$(TARGET_ARCH) common drivers lib test
 define all_sources
-    ( find arch/$(TARGET_ARCH)/include -name '*.h' -print; \
-      find include -name '*.h' -print; \
-      find $(SUBDIRS) -name '*.[chS]' -print )
+    ( find include -type f -name '*.h' -print; \
+      find $(SUBDIRS) -type f -name '*.[chS]' -print )
 endef
 
 define set_exuberant_flags
-- 
2.11.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-12-16 17:24 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-16  9:20 [PATCH] xen/build: Fix `make cscope` rune Andrew Cooper
2021-12-16 14:00 ` Jan Beulich
2021-12-16 14:58   ` Andrew Cooper
2021-12-16 15:15     ` Jan Beulich
2021-12-16 15:18       ` Andrew Cooper
2021-12-16 14:41 ` Anthony PERARD
2021-12-16 17:23 ` Volodymyr Babchuk

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.