From: Sam Ravnborg <sam@ravnborg.org>
To: Jiri Olsa <jolsa@redhat.com>
Cc: linux-kernel@vger.kernel.org,
Arnaldo Carvalho de Melo <acme@ghostprotocols.net>,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Ingo Molnar <mingo@elte.hu>, Paul Mackerras <paulus@samba.org>,
Corey Ashford <cjashfor@linux.vnet.ibm.com>,
Frederic Weisbecker <fweisbec@gmail.com>,
Namhyung Kim <namhyung@kernel.org>,
Borislav Petkov <bp@alien8.de>,
Stephane Eranian <eranian@google.com>
Subject: Re: [PATCH 03/27] perf tools: Move arch check into config/Makefile
Date: Mon, 1 Apr 2013 21:54:46 +0200 [thread overview]
Message-ID: <20130401195446.GC5744@merkur.ravnborg.org> (raw)
In-Reply-To: <1364843930-17974-4-git-send-email-jolsa@redhat.com>
On Mon, Apr 01, 2013 at 09:18:26PM +0200, Jiri Olsa wrote:
> Moving arch check into config/Makefile.
>
> Signed-off-by: Jiri Olsa <jolsa@redhat.com>
> Cc: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
> Cc: Ingo Molnar <mingo@elte.hu>
> Cc: Paul Mackerras <paulus@samba.org>
> Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
> Cc: Frederic Weisbecker <fweisbec@gmail.com>
> Cc: Namhyung Kim <namhyung@kernel.org>
> Cc: Borislav Petkov <bp@alien8.de>
> Cc: Stephane Eranian <eranian@google.com>
> ---
> tools/perf/Makefile | 31 ++-----------------------------
> tools/perf/config/Makefile | 34 ++++++++++++++++++++++++++++++++++
> 2 files changed, 36 insertions(+), 29 deletions(-)
> create mode 100644 tools/perf/config/Makefile
>
> diff --git a/tools/perf/Makefile b/tools/perf/Makefile
> index c8fb0fd..032e099 100644
> --- a/tools/perf/Makefile
> +++ b/tools/perf/Makefile
> @@ -55,37 +55,11 @@ include config/utilities.mak
> $(OUTPUT)PERF-VERSION-FILE: .FORCE-PERF-VERSION-FILE
> @$(SHELL_PATH) util/PERF-VERSION-GEN $(OUTPUT)
>
> -uname_M := $(shell uname -m 2>/dev/null || echo not)
> -
> -ARCH ?= $(shell echo $(uname_M) | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ \
> - -e s/arm.*/arm/ -e s/sa110/arm/ \
> - -e s/s390x/s390/ -e s/parisc64/parisc/ \
> - -e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
> - -e s/sh[234].*/sh/ -e s/aarch64.*/arm64/ )
> -NO_PERF_REGS := 1
> -
> CC = $(CROSS_COMPILE)gcc
> AR = $(CROSS_COMPILE)ar
>
> -# Additional ARCH settings for x86
> -ifeq ($(ARCH),i386)
> - override ARCH := x86
> - NO_PERF_REGS := 0
> - LIBUNWIND_LIBS = -lunwind -lunwind-x86
> -endif
> -ifeq ($(ARCH),x86_64)
> - override ARCH := x86
> - IS_X86_64 := 0
> - ifeq (, $(findstring m32,$(EXTRA_CFLAGS)))
> - IS_X86_64 := $(shell echo __x86_64__ | ${CC} -E -x c - | tail -n 1)
> - endif
> - ifeq (${IS_X86_64}, 1)
> - RAW_ARCH := x86_64
> - ARCH_CFLAGS := -DARCH_X86_64
> - ARCH_INCLUDE = ../../arch/x86/lib/memcpy_64.S ../../arch/x86/lib/memset_64.S
> - endif
> - NO_PERF_REGS := 0
> - LIBUNWIND_LIBS = -lunwind -lunwind-x86_64
> +ifeq ($(filter clean tags,$(MAKECMDGOALS)),)
> +include config/Makefile
> endif
>
> # Treat warnings as errors unless directed not to
> @@ -857,7 +831,6 @@ ifeq ($(NO_PERF_REGS),0)
> ifeq ($(ARCH),x86)
> LIB_H += arch/x86/include/perf_regs.h
> endif
> - BASIC_CFLAGS += -DHAVE_PERF_REGS
> endif
>
> ifndef NO_STRLCPY
> diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile
> new file mode 100644
> index 0000000..fe317c2
> --- /dev/null
> +++ b/tools/perf/config/Makefile
> @@ -0,0 +1,34 @@
> +uname_M := $(shell uname -m 2>/dev/null || echo not)
> +
> +ARCH ?= $(shell echo $(uname_M) | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ \
> + -e s/arm.*/arm/ -e s/sa110/arm/ \
> + -e s/s390x/s390/ -e s/parisc64/parisc/ \
> + -e s/ppc.*/powerpc/ -e s/mips.*/mips/ \
> + -e s/sh[234].*/sh/ -e s/aarch64.*/arm64/ )
this is shared with the top-level kernel Makefile.
Could we find a way to share this?
Sam
next prev parent reply other threads:[~2013-04-01 19:54 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-01 19:18 [RFC 00/27] perf tools: Build changes and kbuild support Jiri Olsa
2013-04-01 19:18 ` [PATCH 01/27] perf tools: Add automated make test suite Jiri Olsa
2013-04-01 19:53 ` Sam Ravnborg
2013-04-01 21:09 ` Jiri Olsa
2013-04-01 19:18 ` [PATCH 02/27] perf tools: Fix tab vs spaces issue in Makefile ifdef/endif Jiri Olsa
2013-04-01 19:49 ` Sam Ravnborg
2013-04-01 21:11 ` Jiri Olsa
2013-04-01 19:18 ` [PATCH 03/27] perf tools: Move arch check into config/Makefile Jiri Olsa
2013-04-01 19:54 ` Sam Ravnborg [this message]
2013-04-01 21:07 ` Jiri Olsa
2013-04-01 21:54 ` Namhyung Kim
2013-04-01 22:00 ` Jiri Olsa
2013-04-01 19:18 ` [PATCH 04/27] perf tools: Move programs " Jiri Olsa
2013-04-01 22:09 ` Namhyung Kim
2013-04-01 22:27 ` Jiri Olsa
2013-04-02 3:59 ` Namhyung Kim
2013-04-01 19:18 ` [PATCH 05/27] perf tools: Move compiler and linker flags " Jiri Olsa
2013-04-01 22:20 ` Namhyung Kim
2013-04-01 23:06 ` Jiri Olsa
2013-04-01 19:18 ` [PATCH 06/27] perf tools: Move libelf check config " Jiri Olsa
2013-04-01 19:18 ` [PATCH 07/27] perf tools: Move libdw " Jiri Olsa
2013-04-01 19:18 ` [PATCH 08/27] perf tools: Move libunwind " Jiri Olsa
2013-04-01 19:18 ` [PATCH 09/27] perf tools: Move libaudit " Jiri Olsa
2013-04-01 19:18 ` [PATCH 10/27] perf tools: Move slang " Jiri Olsa
2013-04-01 19:18 ` [PATCH 11/27] perf tools: Move gtk2 " Jiri Olsa
2013-04-01 19:18 ` [PATCH 12/27] perf tools: Move libperl " Jiri Olsa
2013-04-01 19:18 ` [PATCH 13/27] perf tools: Move libpython " Jiri Olsa
2013-04-01 19:18 ` [PATCH 14/27] perf tools: Move libbfd " Jiri Olsa
2013-04-01 19:18 ` [PATCH 15/27] perf tools: Move stdlib " Jiri Olsa
2013-04-01 19:18 ` [PATCH 16/27] perf tools: Move libnuma " Jiri Olsa
2013-04-01 19:18 ` [PATCH 17/27] perf tools: Move paths " Jiri Olsa
2013-04-01 19:18 ` [PATCH 18/27] perf tools: Final touches for CHK config move Jiri Olsa
2013-04-01 19:18 ` [PATCH 19/27] perf tools: Merge all *CFLAGS* make variable into CFLAGS Jiri Olsa
2013-04-01 19:18 ` [PATCH 20/27] perf tools: Merge all *LDFLAGS* make variable into LDFLAGS Jiri Olsa
2013-04-01 19:18 ` [PATCH 21/27] perf tools: Switch to full patch C include directories Jiri Olsa
2013-04-01 19:18 ` [PATCH 22/27] perf tools: Add NO_BIONIC variable to confiure bionic setup Jiri Olsa
2013-04-01 19:18 ` [PATCH 23/27] kbuild: Introduce KBUILD_AUTOCONF variable for auto.conf include Jiri Olsa
2013-04-01 19:18 ` [PATCH 24/27] kbuild: Introduce KCONFIG_AUTOCONFIGDEP variable for conf tool Jiri Olsa
2013-04-11 10:29 ` Michal Marek
2013-04-01 19:18 ` [PATCH 25/27] perf tools: Kbuild builtin source related fixies Jiri Olsa
2013-04-01 19:18 ` [PATCH 26/27] perf tools: Kbuild " Jiri Olsa
2013-04-01 19:18 ` [PATCH 27/27] perf tools: Add kbuild support into Makefile.kbuild Jiri Olsa
2013-04-01 20:03 ` Sam Ravnborg
2013-04-01 21:05 ` Jiri Olsa
2013-04-01 20:45 ` [RFC 00/27] perf tools: Build changes and kbuild support David Ahern
2013-04-01 21:18 ` 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=20130401195446.GC5744@merkur.ravnborg.org \
--to=sam@ravnborg.org \
--cc=a.p.zijlstra@chello.nl \
--cc=acme@ghostprotocols.net \
--cc=bp@alien8.de \
--cc=cjashfor@linux.vnet.ibm.com \
--cc=eranian@google.com \
--cc=fweisbec@gmail.com \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=namhyung@kernel.org \
--cc=paulus@samba.org \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®