diff options
author | John Kacur <jkacur@redhat.com> | 2010-03-11 07:57:00 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2010-03-11 08:08:11 -0500 |
commit | 7ae5f21361fea11f58c398701da635f778635d13 (patch) | |
tree | f6bcf809f93ef4133f4edb9e8f0fa770aacde9a7 /tools/perf/Makefile | |
parent | 83ff56f46a8532488ee364bb93a9cb2a59490d33 (diff) |
perf: Make the install relative to DESTDIR if specified
Without this change, the install path is relative to
prefix/DESTDIR where prefix is automatically set to $HOME.
This can produce unexpected results. For example:
make -C tools/perf DESTDIR=/home/jkacur/tmp install-man
creates the directory: /home/jkacur/home/jkacur/tmp/share/...
instead of the expected: /home/jkacur/tmp/share/...
Signed-off-by: John Kacur <jkacur@redhat.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Tom Zanussi <tzanussi@gmail.com>
Cc: Kyle McMartin <kyle@redhat.com>
Cc: <stable@kernel.org>
LKML-Reference: <1268312220-12880-1-git-send-email-jkacur@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'tools/perf/Makefile')
-rw-r--r-- | tools/perf/Makefile | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/perf/Makefile b/tools/perf/Makefile index 5840499e2d22..8a8f52db7e38 100644 --- a/tools/perf/Makefile +++ b/tools/perf/Makefile | |||
@@ -216,7 +216,10 @@ STRIP ?= strip | |||
216 | # runtime figures out where they are based on the path to the executable. | 216 | # runtime figures out where they are based on the path to the executable. |
217 | # This can help installing the suite in a relocatable way. | 217 | # This can help installing the suite in a relocatable way. |
218 | 218 | ||
219 | # Make the path relative to DESTDIR, not to prefix | ||
220 | ifndef DESTDIR | ||
219 | prefix = $(HOME) | 221 | prefix = $(HOME) |
222 | endif | ||
220 | bindir_relative = bin | 223 | bindir_relative = bin |
221 | bindir = $(prefix)/$(bindir_relative) | 224 | bindir = $(prefix)/$(bindir_relative) |
222 | mandir = share/man | 225 | mandir = share/man |
@@ -233,7 +236,6 @@ sysconfdir = $(prefix)/etc | |||
233 | ETC_PERFCONFIG = etc/perfconfig | 236 | ETC_PERFCONFIG = etc/perfconfig |
234 | endif | 237 | endif |
235 | lib = lib | 238 | lib = lib |
236 | # DESTDIR= | ||
237 | 239 | ||
238 | export prefix bindir sharedir sysconfdir | 240 | export prefix bindir sharedir sysconfdir |
239 | 241 | ||