summaryrefslogtreecommitdiffstats
path: root/makefile.rules
diff options
context:
space:
mode:
authorJuergen Beisert <jbe@pengutronix.de>2011-06-06 17:01:56 +0200
committerJuergen Beisert <jbe@pengutronix.de>2011-06-06 17:01:56 +0200
commit62f081828221741fb945927ae85c496c431c9f84 (patch)
tree962ab36914ba87b74ae82ae455b706d1a6c135ec /makefile.rules
parentdd57c62797d2b8d05e224680c7bc6e3d4640dde0 (diff)
downloadmxs-utils-62f081828221741fb945927ae85c496c431c9f84.tar.gz
mxs-utils-62f081828221741fb945927ae85c496c431c9f84.tar.xz
A Makefile always should provide an 'install' stage
Providing an 'install' stage simplyfies its integration into PTXdist. Signed-off-by: Juergen Beisert <jbe@pengutronix.de>
Diffstat (limited to 'makefile.rules')
-rw-r--r--makefile.rules7
1 files changed, 7 insertions, 0 deletions
diff --git a/makefile.rules b/makefile.rules
index 9cd649e..1d24eb7 100644
--- a/makefile.rules
+++ b/makefile.rules
@@ -101,6 +101,8 @@ OBJ_FILES_KEYGEN = \
keygen.o
+PREFIX := /usr/local
+
LIBS = -lstdc++
@@ -120,6 +122,8 @@ endif # ifeq ("${UNAMES}", "Linux")
#*******************************************************************************
# Targets
+.PHONY := all install clean
+
all: elftosb sbtool keygen
# Uncomment the next line to print out the environment variables.
@@ -176,3 +180,6 @@ keygen: ${OBJ_FILES_KEYGEN}
[ -s $@ ] || rm -f $@
#*******************************************************************************
+
+install: all
+ install -t $(DESTDIR)/$(PREFIX)/bin ${EXEC_FILE_ELFTOSB2} ${EXEC_FILE_SBTOOL} ${EXEC_FILE_KEYGEN}