diff mbox

[1/6] build: make PREFIX overwritable from the environment

Message ID 20171004132605.24734-2-uwe@kleine-koenig.org (mailing list archive)
State Mainlined, archived
Headers show

Commit Message

Uwe Kleine-König Oct. 4, 2017, 1:26 p.m. UTC
This way I can just use

	env PREFIX=/usr make install

on the command line to install sparse into the system.

Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/Makefile b/Makefile
index d0341764158e..e011df3cc0dc 100644
--- a/Makefile
+++ b/Makefile
@@ -54,7 +54,7 @@  BASIC_CFLAGS += -Wp,-MD,$(@D)/.$(@F).d
 endif
 
 DESTDIR=
-PREFIX=$(HOME)
+PREFIX ?= $(HOME)
 BINDIR=$(PREFIX)/bin
 LIBDIR=$(PREFIX)/lib
 MANDIR=$(PREFIX)/share/man