We plan to put those tools in separate rpm,
so we need a way to install them.
Adding install target with standard DESTDIR
and prefix make variables.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
INCLUDES := -I$(OUTPUT)
CFLAGS := -g -O2 -Wall
ARCH := $(shell uname -m | sed 's/x86_64/x86/')
+INSTALL ?= install
+prefix ?= /usr/local
APPS = \
biolatency \
INCLUDEDIR= LIBDIR= UAPIDIR= \
install
+install: $(APPS)
+ $(call msg, INSTALL libbpf-tools)
+ $(Q)$(INSTALL) -m 0755 -d $(DESTDIR)$(prefix)/bin
+ $(Q)$(INSTALL) $(APPS) $(DESTDIR)$(prefix)/bin
+
# delete failed targets
.DELETE_ON_ERROR:
# keep intermediate (.skel.h, .bpf.o, etc) targets