linux-trace-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] trace-cmd: Make the build messages to show only file names
@ 2018-02-08  9:18 Vladislav Valtchev (VMware)
  2018-02-08 15:31 ` Steven Rostedt
  0 siblings, 1 reply; 2+ messages in thread
From: Vladislav Valtchev (VMware) @ 2018-02-08  9:18 UTC (permalink / raw)
  To: rostedt
  Cc: linux-trace-devel, linux-kernel, y.karadz,
	Vladislav Valtchev (VMware)

Currently, the typical trace-cmd build messages like "COMPILE <file>" and
"BUILD STATIC LIB <file>" show file's full path, instead of just the file
name, as it used to happen before the full support for out-of-tree builds.
This simple patch makes the build messages to look exactly like in the past
by stripping the directory part of each file path, before printing the
message.

Signed-off-by: Vladislav Valtchev (VMware) <vladislav.valtchev@gmail.com>
---
 scripts/utils.mk | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/scripts/utils.mk b/scripts/utils.mk
index 06e8dc3..ad31f6e 100644
--- a/scripts/utils.mk
+++ b/scripts/utils.mk
@@ -3,14 +3,14 @@
 
 ifeq ($(BUILDGUI), 1)
   GUI		= 'GUI '
-  GOBJ		= $@
   GSPACE	=
 else
   GUI		=
   GSPACE	= "    "
-  GOBJ		= $(GSPACE)$@
 endif
 
+ GOBJ		= $(GSPACE)$(notdir $(strip $@))
+
 
 ifeq ($(VERBOSE),1)
   Q =
@@ -81,22 +81,22 @@ define make_version.h
 endef
 
 define update_version.h
-	($(call make_version.h, $@.tmp);		\
-	if [ -r $@ ] && cmp -s $@ $@.tmp; then		\
-		rm -f $@.tmp;				\
-	else						\
-		echo '  UPDATE                 $@';	\
-		mv -f $@.tmp $@;			\
+	($(call make_version.h, $@.tmp);				\
+	if [ -r $@ ] && cmp -s $@ $@.tmp; then				\
+		rm -f $@.tmp;						\
+	else								\
+		echo '  UPDATE                 '$(notdir $(strip $@));	\
+		mv -f $@.tmp $@;					\
 	fi);
 endef
 
 define update_dir
 	(echo $1 > $@.tmp;	\
-	if [ -r $@ ] && cmp -s $@ $@.tmp; then		\
-		rm -f $@.tmp;				\
-	else						\
-		echo '  UPDATE                 $@';	\
-		mv -f $@.tmp $@;			\
+	if [ -r $@ ] && cmp -s $@ $@.tmp; then				\
+		rm -f $@.tmp;						\
+	else								\
+		echo '  UPDATE                 '$(notdir $(strip $@));	\
+		mv -f $@.tmp $@;					\
 	fi);
 endef
 
-- 
2.14.1

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

* Re: [PATCH] trace-cmd: Make the build messages to show only file names
  2018-02-08  9:18 [PATCH] trace-cmd: Make the build messages to show only file names Vladislav Valtchev (VMware)
@ 2018-02-08 15:31 ` Steven Rostedt
  0 siblings, 0 replies; 2+ messages in thread
From: Steven Rostedt @ 2018-02-08 15:31 UTC (permalink / raw)
  To: Vladislav Valtchev (VMware); +Cc: linux-trace-devel, linux-kernel, y.karadz

On Thu,  8 Feb 2018 11:18:20 +0200
"Vladislav Valtchev (VMware)" <vladislav.valtchev@gmail.com> wrote:

> Currently, the typical trace-cmd build messages like "COMPILE <file>" and
> "BUILD STATIC LIB <file>" show file's full path, instead of just the file
> name, as it used to happen before the full support for out-of-tree builds.
> This simple patch makes the build messages to look exactly like in the past
> by stripping the directory part of each file path, before printing the
> message.
> 
>

Thanks, applied!

-- Steve

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

end of thread, other threads:[~2018-02-08 15:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-08  9:18 [PATCH] trace-cmd: Make the build messages to show only file names Vladislav Valtchev (VMware)
2018-02-08 15:31 ` Steven Rostedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).