From: tip-bot for Steven Rostedt <rostedt@goodmis.org>
To: linux-tip-commits@vger.kernel.org
Cc: acme@redhat.com, linux-kernel@vger.kernel.org, hpa@zytor.com,
mingo@kernel.org, peterz@infradead.org, namhyung.kim@lge.com,
rostedt@goodmis.org, tglx@linutronix.de, borislav.petkov@amd.com
Subject: [tip:perf/core] perf tools: Let O= makes handle relative paths
Date: Tue, 21 Aug 2012 09:20:00 -0700 [thread overview]
Message-ID: <tip-c883122acc0d97648d8b8f4726709017674e4420@git.kernel.org> (raw)
In-Reply-To: <20120815163923.GD15989@aftab.osrc.amd.com>
Commit-ID: c883122acc0d97648d8b8f4726709017674e4420
Gitweb: http://git.kernel.org/tip/c883122acc0d97648d8b8f4726709017674e4420
Author: Steven Rostedt <rostedt@goodmis.org>
AuthorDate: Mon, 13 Aug 2012 10:23:02 -0400
Committer: Arnaldo Carvalho de Melo <acme@redhat.com>
CommitDate: Thu, 16 Aug 2012 14:11:11 -0300
perf tools: Let O= makes handle relative paths
When I did a compile of perf using a relative path for the output
directory, the build failed when it tried to compile libtraceevent. This
is because it continues to use the same relative path when the new
working directory is in a different path.
SUBDIR ../lib/traceevent/
/bin/sh: line 0: cd: ../../../nobackup/perf/: No such file or directory
Makefile:74: *** output directory "../../../nobackup/perf/" does not exist. Stop.
make: *** [../../../nobackup/perf///libtraceevent.a] Error 2
Make the path used an absolute path when building perf with O=.
Boris:
Teach Makefile to check whether the supplied O= directory exists and
bail out if not. Reportedly, kernel dudes are idiots and need to be
guarded so as not to shoot themselves in the foot when playing in the
sandbox.
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Acked-by: Steven Rostedt <rostedt@goodmis.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Namhyung Kim <namhyung.kim@lge.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20120815163923.GD15989@aftab.osrc.amd.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/scripts/Makefile.include | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/tools/scripts/Makefile.include b/tools/scripts/Makefile.include
index bde8521..96ce80a 100644
--- a/tools/scripts/Makefile.include
+++ b/tools/scripts/Makefile.include
@@ -1,6 +1,8 @@
ifeq ("$(origin O)", "command line")
- OUTPUT := $(O)/
- COMMAND_O := O=$(O)
+ dummy := $(if $(shell test -d $(O) || echo $(O)),$(error O=$(O) does not exist),)
+ ABSOLUTE_O := $(shell cd $(O) ; pwd)
+ OUTPUT := $(ABSOLUTE_O)/
+ COMMAND_O := O=$(ABSOLUTE_O)
endif
ifneq ($(OUTPUT),)
prev parent reply other threads:[~2012-08-21 16:20 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-13 13:20 [PATCH] perf: Let O= makes handle relative paths Steven Rostedt
2012-08-13 13:24 ` Borislav Petkov
2012-08-13 14:23 ` Steven Rostedt
2012-08-13 14:29 ` Borislav Petkov
2012-08-13 18:02 ` Arnaldo Carvalho de Melo
2012-08-15 10:27 ` Borislav Petkov
2012-08-15 13:06 ` Arnaldo Carvalho de Melo
2012-08-15 13:18 ` Borislav Petkov
2012-08-15 14:38 ` Peter Zijlstra
2012-08-15 14:42 ` Borislav Petkov
2012-08-15 14:59 ` Arnaldo Carvalho de Melo
2012-08-15 16:39 ` Borislav Petkov
2012-08-16 16:07 ` Steven Rostedt
2012-08-16 17:12 ` Arnaldo Carvalho de Melo
2012-08-21 16:20 ` tip-bot for Steven Rostedt [this message]
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-c883122acc0d97648d8b8f4726709017674e4420@git.kernel.org \
--to=rostedt@goodmis.org \
--cc=acme@redhat.com \
--cc=borislav.petkov@amd.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung.kim@lge.com \
--cc=peterz@infradead.org \
--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