tools/turbostat: allow user to alter DESTDIR and PREFIX
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Fri, 17 Jun 2016 12:59:33 +0000 (15:59 +0300)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 27 Jun 2016 22:37:04 +0000 (00:37 +0200)
When run
make -C tools DESTDIR=/my/nice/dir turbostat_install
get a message
install: cannot create regular file '/usr/bin/turbostat': Permission denied

Allow user to alter DESTDIR and PREFIX variables.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
tools/power/x86/turbostat/Makefile

index e367b1a85d70b3e0b7d82c5766d83a31ce006d2a..8561e7ddca59e7ce4267f08039a8105df2771645 100644 (file)
@@ -1,7 +1,7 @@
 CC             = $(CROSS_COMPILE)gcc
 BUILD_OUTPUT   := $(CURDIR)
-PREFIX         := /usr
-DESTDIR                :=
+PREFIX         ?= /usr
+DESTDIR                ?=
 
 ifeq ("$(origin O)", "command line")
        BUILD_OUTPUT := $(O)