Commit f0bd658f authored by Lance Hartmann's avatar Lance Hartmann Committed by Jim Harris
Browse files

build: Install targets for nvme perf and identify



Introduces new macro INSTALL_EXAMPLE and two example apps,
examples/nvme/perf and example/nvme/identify that make
use of it to install them while at the same time
renaming them in the target directory based on the
source directory path relative to examples.

Change-Id: I2d850458bb2589f80e0af6fb7a9d00aa3bbc6907
Signed-off-by: default avatarLance Hartmann <lance.hartmann@oracle.com>
Reviewed-on: https://review.gerrithub.io/429963


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>
Reviewed-by: default avatarPawel Wodkowski <pawelx.wodkowski@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
parent c0427498
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -36,4 +36,7 @@ include $(SPDK_ROOT_DIR)/mk/spdk.common.mk

APP = identify

install: $(APP)
	$(INSTALL_EXAMPLE)

include $(SPDK_ROOT_DIR)/mk/nvme.libtest.mk
+3 −0
Original line number Diff line number Diff line
@@ -41,4 +41,7 @@ SYS_LIBS += -laio
CFLAGS += -DHAVE_LIBAIO
endif

install: $(APP)
	$(INSTALL_EXAMPLE)

include $(SPDK_ROOT_DIR)/mk/nvme.libtest.mk
+5 −0
Original line number Diff line number Diff line
@@ -287,6 +287,11 @@ INSTALL_APP=\
	install -d -m 755 "$(DESTDIR)$(bindir)"; \
	install -m 755 "$(APP)" "$(DESTDIR)$(bindir)/"

INSTALL_EXAMPLE=\
	$(Q)echo "  INSTALL $(DESTDIR)$(bindir)/spdk_$(strip $(subst /,_,$(subst $(SPDK_ROOT_DIR)/examples/, ,$(CURDIR))))"; \
	install -d -m 755 "$(DESTDIR)$(bindir)"; \
	install -m 755 "$(APP)" "$(DESTDIR)$(bindir)/spdk_$(strip $(subst /,_,$(subst $(SPDK_ROOT_DIR)/examples/, ,$(CURDIR))))"

# Install a header
INSTALL_HEADER=\
	$(Q)echo "  INSTALL $@"; \