LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Jiri Olsa <jolsa@kernel.org>
To: linux-kernel@vger.kernel.org
Cc: Jiri Olsa <jolsa@kernel.org>,
	Alexis Berlemont <alexis.berlemont@gmail.com>,
	Arnaldo Carvalho de Melo <acme@redhat.com>,
	Borislav Petkov <bp@alien8.de>,
	Corey Ashford <cjashfor@linux.vnet.ibm.com>,
	David Ahern <dsahern@gmail.com>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Ingo Molnar <mingo@kernel.org>,
	Namhyung Kim <namhyung@kernel.org>,
	Paul Mackerras <paulus@samba.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Stephane Eranian <eranian@google.com>
Subject: [PATCH 36/36] perf build: Display make commands on V=1
Date: Mon, 26 Jan 2015 11:12:36 +0100	[thread overview]
Message-ID: <1422267156-13873-37-git-send-email-jolsa@kernel.org> (raw)
In-Reply-To: <1422267156-13873-1-git-send-email-jolsa@kernel.org>

Get more verbose output wrt displaying executed commands
from make.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Tested-by: Sukadev Bhattiprolu <sukadev@linux.vnet.ibm.com>
Tested-by: Will Deacon <will.deacon@arm.com>
Cc: Alexis Berlemont <alexis.berlemont@gmail.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
---
 tools/build/Makefile.build |  4 +++-
 tools/perf/Makefile.perf   | 48 ++++++++++++++++++++++++++--------------------
 2 files changed, 30 insertions(+), 22 deletions(-)

diff --git a/tools/build/Makefile.build b/tools/build/Makefile.build
index b5ded207f49b..10df57237a66 100644
--- a/tools/build/Makefile.build
+++ b/tools/build/Makefile.build
@@ -13,8 +13,10 @@ __build:
 
 ifeq ($(V),1)
   quiet =
+  Q =
 else
   quiet=quiet_
+  Q=@
 endif
 
 build-dir := $(srctree)/tools/build
@@ -102,7 +104,7 @@ in-target := $(prefix)$(obj)-in.o
 PHONY += $(subdir-y)
 
 $(subdir-y):
-	@$(MAKE) -f $(build-dir)/Makefile.build dir=$(dir)/$@ obj=$(obj)
+	$(Q)$(MAKE) -f $(build-dir)/Makefile.build dir=$(dir)/$@ obj=$(obj)
 
 $(sort $(subdir-obj-y)): $(subdir-y) ;
 
diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index 5b083da3b934..7850ab25c178 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -89,13 +89,19 @@ VPATH += $(OUTPUT)
 export VPATH
 endif
 
+ifeq ($(V),1)
+  Q =
+else
+  Q = @
+endif
+
 # Do not use make's built-in rules
 # (this increases performance and avoids hard-to-debug behaviour);
 MAKEFLAGS += -r
 
 $(OUTPUT)PERF-VERSION-FILE: ../../.git/HEAD
-	@$(SHELL_PATH) util/PERF-VERSION-GEN $(OUTPUT)
-	@touch $(OUTPUT)PERF-VERSION-FILE
+	$(Q)$(SHELL_PATH) util/PERF-VERSION-GEN $(OUTPUT)
+	$(Q)touch $(OUTPUT)PERF-VERSION-FILE
 
 CC = $(CROSS_COMPILE)gcc
 LD = $(CROSS_COMPILE)ld
@@ -251,7 +257,7 @@ SHELL = $(SHELL_PATH)
 all: shell_compatibility_test $(ALL_PROGRAMS) $(LANG_BINDINGS) $(OTHER_PROGRAMS)
 
 please_set_SHELL_PATH_to_a_more_modern_shell:
-	@$$(:)
+	$(Q)$$(:)
 
 shell_compatibility_test: please_set_SHELL_PATH_to_a_more_modern_shell
 
@@ -264,13 +270,13 @@ export srctree OUTPUT RM CC LD AR CFLAGS V BISON FLEX
 build := -f $(srctree)/tools/build/Makefile.build dir=. obj
 
 $(PERF_IN): $(OUTPUT)PERF-VERSION-FILE $(OUTPUT)common-cmds.h FORCE
-	@$(MAKE) $(build)=perf
+	$(Q)$(MAKE) $(build)=perf
 
 $(OUTPUT)perf: $(PERFLIBS) $(PERF_IN)
 	$(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $(PERF_IN) $(LIBS) -o $@
 
 $(GTK_IN): FORCE
-	@$(MAKE) $(build)=gtk
+	$(Q)$(MAKE) $(build)=gtk
 
 $(OUTPUT)libperf-gtk.so: $(GTK_IN) $(PERFLIBS)
 	$(QUIET_LINK)$(CC) -o $@ -shared $(LDFLAGS) $(filter %.o,$^) $(GTK_LIBS)
@@ -315,25 +321,25 @@ build-dir   = $(if $(__build-dir),$(__build-dir),.)
 single_dep: $(OUTPUT)PERF-VERSION-FILE $(OUTPUT)common-cmds.h
 
 $(OUTPUT)%.o: %.c single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)%.i: %.c single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)%.s: %.c single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)%-bison.o: %.c single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)%-flex.o: %.c single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)%.o: %.S single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)%.i: %.S single_dep FORCE
-	@$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
+	$(Q)$(MAKE) -f $(srctree)/tools/build/Makefile.build dir=$(build-dir) $@
 
 $(OUTPUT)perf-%: %.o $(PERFLIBS)
 	$(QUIET_LINK)$(CC) $(CFLAGS) -o $@ $(LDFLAGS) $(filter %.o,$^) $(LIBS)
@@ -353,7 +359,7 @@ $(patsubst perf-%,%.o,$(PROGRAMS)): $(wildcard */*.h)
 LIBPERF_IN := $(OUTPUT)libperf-in.o
 
 $(LIBPERF_IN): FORCE
-	@$(MAKE) $(build)=libperf
+	$(Q)$(MAKE) $(build)=libperf
 
 $(LIB_FILE): $(LIBPERF_IN)
 	$(QUIET_AR)$(RM) $@ && $(AR) rcs $@ $(LIBPERF_IN) $(LIB_OBJS)
@@ -362,21 +368,21 @@ LIBTRACEEVENT_FLAGS += CFLAGS="-g -Wall $(EXTRA_CFLAGS)"
 LIBTRACEEVENT_FLAGS += plugin_dir=$(plugindir_SQ)
 
 $(LIBTRACEEVENT): FORCE
-	@$(MAKE) -C $(TRACE_EVENT_DIR) $(LIBTRACEEVENT_FLAGS) O=$(OUTPUT) $(OUTPUT)libtraceevent.a plugins
+	$(Q)$(MAKE) -C $(TRACE_EVENT_DIR) $(LIBTRACEEVENT_FLAGS) O=$(OUTPUT) $(OUTPUT)libtraceevent.a plugins
 
 $(LIBTRACEEVENT)-clean:
 	$(call QUIET_CLEAN, libtraceevent)
-	@$(MAKE) -C $(TRACE_EVENT_DIR) O=$(OUTPUT) clean >/dev/null
+	$(Q)$(MAKE) -C $(TRACE_EVENT_DIR) O=$(OUTPUT) clean >/dev/null
 
 install-traceevent-plugins: $(LIBTRACEEVENT)
-	@$(MAKE) -C $(TRACE_EVENT_DIR) $(LIBTRACEEVENT_FLAGS) O=$(OUTPUT) install_plugins
+	$(Q)$(MAKE) -C $(TRACE_EVENT_DIR) $(LIBTRACEEVENT_FLAGS) O=$(OUTPUT) install_plugins
 
 $(LIBAPIKFS): FORCE
-	@$(MAKE) -C $(LIB_DIR) O=$(OUTPUT) $(OUTPUT)libapi.a
+	$(Q)$(MAKE) -C $(LIB_DIR) O=$(OUTPUT) $(OUTPUT)libapi.a
 
 $(LIBAPIKFS)-clean:
 	$(call QUIET_CLEAN, libapi)
-	@$(MAKE) -C $(LIB_DIR) O=$(OUTPUT) clean >/dev/null
+	$(Q)$(MAKE) -C $(LIB_DIR) O=$(OUTPUT) clean >/dev/null
 
 help:
 	@echo 'Perf make targets:'
@@ -514,12 +520,12 @@ $(INSTALL_DOC_TARGETS):
 #
 config-clean:
 	$(call QUIET_CLEAN, config)
-	@$(MAKE) -C config/feature-checks clean >/dev/null
+	$(Q)$(MAKE) -C config/feature-checks clean >/dev/null
 
 clean: $(LIBTRACEEVENT)-clean $(LIBAPIKFS)-clean config-clean
 	$(call QUIET_CLEAN, core-objs)  $(RM) $(LIB_FILE) $(OUTPUT)perf-archive $(OUTPUT)perf-with-kcore $(LANG_BINDINGS)
-	@find . -name '*.o' -delete -o -name '\.*.cmd' -delete -o -name '\.*.d' -delete
-	@$(RM) .config-detected
+	$(Q)find . -name '*.o' -delete -o -name '\.*.cmd' -delete -o -name '\.*.d' -delete
+	$(Q)$(RM) .config-detected
 	$(call QUIET_CLEAN, core-progs) $(RM) $(ALL_PROGRAMS) perf perf-read-vdso32 perf-read-vdsox32
 	$(call QUIET_CLEAN, core-gen)   $(RM)  *.spec *.pyc *.pyo */*.pyc */*.pyo $(OUTPUT)common-cmds.h TAGS tags cscope* $(OUTPUT)PERF-VERSION-FILE $(OUTPUT)PERF-FEATURES $(OUTPUT)util/*-bison* $(OUTPUT)util/*-flex*
 	$(QUIET_SUBDIR0)Documentation $(QUIET_SUBDIR1) clean
-- 
1.9.3


  parent reply	other threads:[~2015-01-26 10:16 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-26 10:12 [PATCHv4 00/36] perf tools: New build framework Jiri Olsa
2015-01-26 10:12 ` [PATCH 01/36] tools build: Add new build support Jiri Olsa
2015-01-26 10:12 ` [PATCH 02/36] tools build: Add detected config support Jiri Olsa
2015-01-26 10:12 ` [PATCH 03/36] tools build: Add subdir support Jiri Olsa
2015-01-26 10:12 ` [PATCH 04/36] perf tools: Remove api fs object from python build Jiri Olsa
2015-01-26 10:12 ` [PATCH 05/36] perf build: Disable make's built-in rules Jiri Olsa
2015-01-26 10:12 ` [PATCH 06/36] perf build: Add bench objects building Jiri Olsa
2015-01-26 10:12 ` [PATCH 07/36] perf build: Add tests " Jiri Olsa
2015-01-26 10:12 ` [PATCH 08/36] perf build: Add builtin " Jiri Olsa
2015-01-26 10:12 ` [PATCH 09/36] perf build: Add libperf " Jiri Olsa
2015-01-26 10:12 ` [PATCH 10/36] perf build: Add probe " Jiri Olsa
2015-01-26 10:12 ` [PATCH 11/36] perf build: Add dwarf " Jiri Olsa
2015-01-26 10:12 ` [PATCH 12/36] perf build: Add dwarf unwind " Jiri Olsa
2015-01-26 10:12 ` [PATCH 13/36] perf build: Add ui " Jiri Olsa
2015-01-26 10:12 ` [PATCH 14/36] perf build: Add slang " Jiri Olsa
2015-01-26 10:12 ` [PATCH 15/36] perf build: Add gtk " Jiri Olsa
2015-01-26 10:12 ` [PATCH 16/36] perf build: Add scripts " Jiri Olsa
2015-01-26 10:12 ` [PATCH 17/36] perf build: Add perf regs " Jiri Olsa
2015-01-26 10:12 ` [PATCH 18/36] perf build: Add zlib " Jiri Olsa
2015-01-26 10:12 ` [PATCH 19/36] perf build: Add perf.o object building Jiri Olsa
2015-01-26 10:12 ` [PATCH 20/36] perf build: Add arch x86 objects building Jiri Olsa
2015-01-26 10:12 ` [PATCH 21/36] perf build: Add arch arm " Jiri Olsa
2015-01-26 10:12 ` [PATCH 22/36] perf build: Add arch arm64 " Jiri Olsa
2015-01-26 10:12 ` [PATCH 23/36] perf build: Add arch powerpc " Jiri Olsa
2015-01-26 10:12 ` [PATCH 24/36] perf build: Add arch s390 " Jiri Olsa
2015-01-26 10:12 ` [PATCH 25/36] perf build: Add arch sh " Jiri Olsa
2015-01-26 10:12 ` [PATCH 26/36] perf build: Add arch sparc " Jiri Olsa
2015-01-26 10:12 ` [PATCH 27/36] perf build: Add single target build framework support Jiri Olsa
2015-01-26 10:12 ` [PATCH 28/36] perf build: Remove directory dependency rules Jiri Olsa
2015-01-26 10:12 ` [PATCH 29/36] perf build: Remove uneeded variables Jiri Olsa
2015-01-26 10:12 ` [PATCH 30/36] perf build: Remove PERF-CFLAGS file Jiri Olsa
2015-01-26 10:12 ` [PATCH 31/36] perf build: Add build documentation Jiri Olsa
2015-01-26 10:12 ` [PATCH 32/36] tools lib api: Use tools build framework Jiri Olsa
2015-01-26 10:12 ` [PATCH 33/36] tools lib api: Rename libapikfs.a to libapi.a Jiri Olsa
2015-01-26 10:12 ` [PATCH 34/36] tools lib traceevent: Use tools build framework Jiri Olsa
2015-01-26 10:12 ` [PATCH 35/36] tools lib lockdep: " Jiri Olsa
2015-01-26 10:12 ` Jiri Olsa [this message]
2015-02-02 10:32 ` [PATCHv4 00/36] perf tools: New " Jiri Olsa
2015-02-02 15:26   ` David Ahern
  -- strict thread matches above, loose matches on Subject: below --
2015-01-20 16:38 [PATCHv3 " Jiri Olsa
2015-01-20 16:39 ` [PATCH 36/36] perf build: Display make commands on V=1 Jiri Olsa
2015-01-15 12:54 [PATCHv2 00/36] perf tools: New build framework Jiri Olsa
2015-01-15 12:55 ` [PATCH 36/36] perf build: Display make commands on V=1 Jiri Olsa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1422267156-13873-37-git-send-email-jolsa@kernel.org \
    --to=jolsa@kernel.org \
    --cc=acme@redhat.com \
    --cc=alexis.berlemont@gmail.com \
    --cc=bp@alien8.de \
    --cc=cjashfor@linux.vnet.ibm.com \
    --cc=dsahern@gmail.com \
    --cc=eranian@google.com \
    --cc=fweisbec@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=namhyung@kernel.org \
    --cc=paulus@samba.org \
    --cc=peterz@infradead.org \
    --subject='Re: [PATCH 36/36] perf build: Display make commands on V=1' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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).