Skip to content

Commit

Permalink
perf tools: Fix 'make help' message error
Browse files Browse the repository at this point in the history
Currently 'make help' message has such hint:

   use "make prefix=<path> <install target>" to install to a particular
       path like make prefix=/usr/local install install-doc

But this is misleading, when I specify "prefix=/usr/local", it has got no
respect at all.

This is because that, "DESTDIR" is considered first. In this case, "DESTDIR"
has an empty value, so "prefix" is honored. However, "prefix" is unconditionally
assigned to $HOME, regardless of what it is set to from command line. So our
"prefix" setting got no respect and the actual destination falls back to $HOME.

This patch fixes this issue and corrects the help message.

Signed-off-by: Jianyu Zhan <[email protected]>
Acked-by: Namhyung Kim <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Jiri Olsa <[email protected]>
  • Loading branch information
JianyuZhan authored and olsajiri committed Jun 3, 2014
1 parent a515114 commit fc9cabe
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions tools/perf/Makefile.perf
Original file line number Diff line number Diff line change
Expand Up @@ -789,8 +789,8 @@ help:
@echo ''
@echo 'Perf install targets:'
@echo ' NOTE: documentation build requires asciidoc, xmlto packages to be installed'
@echo ' HINT: use "make prefix=<path> <install target>" to install to a particular'
@echo ' path like make prefix=/usr/local install install-doc'
@echo ' HINT: use "prefix" or "DESTDIR" to install to a particular'
@echo ' path like "make prefix=/usr/local install install-doc"'
@echo ' install - install compiled binaries'
@echo ' install-doc - install *all* documentation'
@echo ' install-man - install manpage documentation'
Expand Down
2 changes: 1 addition & 1 deletion tools/perf/config/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -600,7 +600,7 @@ endif

# Make the path relative to DESTDIR, not to prefix
ifndef DESTDIR
prefix = $(HOME)
prefix ?= $(HOME)
endif
bindir_relative = bin
bindir = $(prefix)/$(bindir_relative)
Expand Down

0 comments on commit fc9cabe

Please sign in to comment.