Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1310496

[PATCH 7/8] perf build: Add feature-dump target

From Arnaldo Carvalho de Melo <acme@kernel.org>
Newsgroups linux.kernel
Subject [PATCH 7/8] perf build: Add feature-dump target
Date 2016-01-15 22:50 +0100
Message-ID <qRkpR-3pW-53@gated-at.bofh.it> (permalink)
References <qRkpP-3pW-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Jiri Olsa <jolsa@kernel.org>

To provide FEATURE-DUMP into $(FEATURE_DUMP_COPY) if defined, with no
further action.

Get feature dump of the current build:
  $ make feature-dump
    BUILD:   Doing 'make -j4' parallel build

  Auto-detecting system features:
  ...                         dwarf: [ on  ]

  FEATURE-DUMP file available in FEATURE-DUMP

Get feature dump static build into /tmp/fd file:

  $ make feature-dump FEATURE_DUMP_COPY=/tmp/fd LDFLAGS=-static
    BUILD:   Doing 'make -j4' parallel build

  Auto-detecting system features:
  ...                         dwarf: [ OFF ]

  SNIP

  FEATURE-DUMP file copied into /tmp/fd

Suggested-by: Wang Nan <wangnan0@huawei.com>
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Zefan Li <lizefan@huawei.com>
Cc: pi3orama@163.com
Link: http://lkml.kernel.org/r/1452830421-77757-6-git-send-email-wangnan0@huawei.com
Signed-off-by: Wang Nan <wangnan0@huawei.com>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
 tools/perf/Makefile.perf | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
index 0a22407e1d7d..f758a72df1b3 100644
--- a/tools/perf/Makefile.perf
+++ b/tools/perf/Makefile.perf
@@ -611,6 +611,17 @@ clean: $(LIBTRACEEVENT)-clean $(LIBAPI)-clean $(LIBBPF)-clean $(LIBSUBCMD)-clean
 	$(python-clean)
 
 #
+# To provide FEATURE-DUMP into $(FEATURE_DUMP_COPY)
+# file if defined, with no further action.
+feature-dump:
+ifdef FEATURE_DUMP_COPY
+	@cp $(OUTPUT)FEATURE-DUMP $(FEATURE_DUMP_COPY)
+	@echo "FEATURE-DUMP file copied into $(FEATURE_DUMP_COPY)"
+else
+	@echo "FEATURE-DUMP file available in $(OUTPUT)FEATURE-DUMP"
+endif
+
+#
 # Trick: if ../../.git does not exist - we are building out of tree for example,
 # then force version regeneration:
 #
-- 
2.1.0

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[GIT PULL 0/8] perf/core improvements and fixes Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 8/8] perf build: Introduce FEATURES_DUMP make variable Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 2/8] perf symbols: Fix reading of build-id from vDSO Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 6/8] perf build: Pass O option to kernel makefile in build-test Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 3/8] perf build: Set parallel making options build-test Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 5/8] perf build: Test correct path of perf in build-test Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 1/8] perf kvm record/report: 'unprocessable sample' error while recording/reporting guest data Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 4/8] perf build: Pass O option to Makefile.perf in build-test Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  [PATCH 7/8] perf build: Add feature-dump target Arnaldo Carvalho de Melo <acme@kernel.org> - 2016-01-15 22:50 +0100
  Re: [GIT PULL 0/8] perf/core improvements and fixes Ingo Molnar <mingo@kernel.org> - 2016-01-19 08:40 +0100

csiph-web