From: tip-bot for Paul Mackerras <paulus@samba.org>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, paulus@samba.org, hpa@zytor.com,
mingo@redhat.com, a.p.zijlstra@chello.nl, tglx@linutronix.de,
mingo@elte.hu
Subject: [tip:perfcounters/core] perf_counter: tools: Makefile tweaks for 64-bit powerpc
Date: Thu, 18 Jun 2009 12:50:01 GMT [thread overview]
Message-ID: <tip-e24a72c4d8f0b2c17783b3ba9c8931b537149423@git.kernel.org> (raw)
In-Reply-To: <19000.55666.866148.559620@cargo.ozlabs.ibm.com>
Commit-ID: e24a72c4d8f0b2c17783b3ba9c8931b537149423
Gitweb: http://git.kernel.org/tip/e24a72c4d8f0b2c17783b3ba9c8931b537149423
Author: Paul Mackerras <paulus@samba.org>
AuthorDate: Wed, 17 Jun 2009 21:54:26 +1000
Committer: Ingo Molnar <mingo@elte.hu>
CommitDate: Thu, 18 Jun 2009 11:11:47 +0200
perf_counter: tools: Makefile tweaks for 64-bit powerpc
On 64-bit powerpc, perf needs to be built as a 64-bit executable.
This arranges to add the -m64 flag to CFLAGS if we are running on
a 64-bit machine, indicated by the result of uname -m ending in "64".
This means that we'll use -m64 on x86_64 machines as well.
Signed-off-by: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: linuxppc-dev@ozlabs.org
Cc: benh@kernel.crashing.org
LKML-Reference: <19000.55666.866148.559620@cargo.ozlabs.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
tools/perf/Makefile | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/tools/perf/Makefile b/tools/perf/Makefile
index e8346f9..714db73 100644
--- a/tools/perf/Makefile
+++ b/tools/perf/Makefile
@@ -157,9 +157,14 @@ uname_R := $(shell sh -c 'uname -r 2>/dev/null || echo not')
uname_P := $(shell sh -c 'uname -p 2>/dev/null || echo not')
uname_V := $(shell sh -c 'uname -v 2>/dev/null || echo not')
+# If we're on a 64-bit kernel, use -m64
+ifneq ($(patsubst %64,%,$(uname_M)),$(uname_M))
+ M64 := -m64
+endif
+
# CFLAGS and LDFLAGS are for the users to override from the command line.
-CFLAGS = -ggdb3 -Wall -Werror -Wstrict-prototypes -Wmissing-declarations -Wmissing-prototypes -std=gnu99 -Wdeclaration-after-statement -O6
+CFLAGS = $(M64) -ggdb3 -Wall -Wstrict-prototypes -Wmissing-declarations -Wmissing-prototypes -std=gnu99 -Wdeclaration-after-statement -O6
LDFLAGS = -lpthread -lrt -lelf -lm
ALL_CFLAGS = $(CFLAGS)
ALL_LDFLAGS = $(LDFLAGS)
next prev parent reply other threads:[~2009-06-18 12:52 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-17 11:50 [PATCH 1/6] perf_counter: powerpc: Enable use of software counters on 32-bit powerpc Paul Mackerras
2009-06-17 11:51 ` [PATCH 2/6] perf_counter: powerpc: Use unsigned long for register and constraint values Paul Mackerras
2009-06-17 14:18 ` [tip:perfcounters/powerpc] " tip-bot for Paul Mackerras
2009-06-18 12:49 ` [tip:perfcounters/core] " tip-bot for Paul Mackerras
2009-06-17 11:52 ` [PATCH 3/6] perf_counter: powerpc: Change how processor-specific back-ends get selected Paul Mackerras
2009-06-17 14:19 ` [tip:perfcounters/powerpc] " tip-bot for Paul Mackerras
2009-06-18 12:49 ` [tip:perfcounters/core] " tip-bot for Paul Mackerras
2009-06-17 11:53 ` [PATCH 4/6] perf_counter: powerpc: Make powerpc perf_counter code safe for 32-bit kernels Paul Mackerras
2009-06-17 14:19 ` [tip:perfcounters/powerpc] " tip-bot for Paul Mackerras
2009-06-18 12:49 ` [tip:perfcounters/core] " tip-bot for Paul Mackerras
2009-06-17 11:53 ` [PATCH 5/6] perf_counter: powerpc: Add processor back-end for MPC7450 family Paul Mackerras
2009-06-17 14:14 ` Kumar Gala
2009-06-17 23:24 ` Paul Mackerras
2009-06-18 12:50 ` Kumar Gala
2009-06-18 21:10 ` Paul Mackerras
2009-06-17 14:19 ` [tip:perfcounters/powerpc] " tip-bot for Paul Mackerras
2009-06-18 12:49 ` [tip:perfcounters/core] " tip-bot for Paul Mackerras
2009-06-17 11:54 ` [PATCH 6/6] perf_counter: tools: Makefile tweaks for 64-bit powerpc Paul Mackerras
2009-06-17 12:08 ` Ingo Molnar
2009-06-17 12:27 ` Paul Mackerras
2009-06-17 13:28 ` Ingo Molnar
2009-06-18 9:13 ` Ingo Molnar
2009-06-19 8:16 ` Paul Mackerras
2009-06-19 16:27 ` Ingo Molnar
2009-06-18 12:50 ` tip-bot for Paul Mackerras [this message]
2009-06-17 12:04 ` [PATCH 1/6] perf_counter: powerpc: Enable use of software counters on 32-bit powerpc Ingo Molnar
2009-06-17 14:10 ` Kumar Gala
2009-06-17 23:22 ` Paul Mackerras
2009-06-17 14:21 ` Ingo Molnar
2009-06-17 14:24 ` Kumar Gala
2009-06-17 14:27 ` Ingo Molnar
2009-06-18 23:03 ` Benjamin Herrenschmidt
2009-06-20 10:32 ` Ingo Molnar
2009-06-17 23:27 ` Paul Mackerras
2009-06-18 9:04 ` Ingo Molnar
2009-06-18 23:01 ` Benjamin Herrenschmidt
2009-06-18 12:48 ` [tip:perfcounters/core] " tip-bot for Paul Mackerras
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=tip-e24a72c4d8f0b2c17783b3ba9c8931b537149423@git.kernel.org \
--to=paulus@samba.org \
--cc=a.p.zijlstra@chello.nl \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mingo@redhat.com \
--cc=tglx@linutronix.de \
/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
Powered by JetHome