summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorThomas Monjalon <thomas.monjalon@6wind.com>2015-12-01 23:59:26 +0100
committerThomas Monjalon <thomas.monjalon@6wind.com>2015-12-06 15:41:04 +0100
commite4552b9cc6036b2310589a0f1aec70aa19b9099f (patch)
tree4547359bc921deebd3a363365883d59798c4baa3 /mk
parent89fd88459715e5f196370b8bde0b92a69bc88c0b (diff)
downloaddpdk-e4552b9cc6036b2310589a0f1aec70aa19b9099f.zip
dpdk-e4552b9cc6036b2310589a0f1aec70aa19b9099f.tar.gz
dpdk-e4552b9cc6036b2310589a0f1aec70aa19b9099f.tar.xz
mk: install doc
The HTML API and HTML/PDF guides may be installed if generated. Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com> Acked-by: Panu Matilainen <pmatilai@redhat.com>
Diffstat (limited to 'mk')
-rw-r--r--mk/rte.sdkinstall.mk14
1 files changed, 14 insertions, 0 deletions
diff --git a/mk/rte.sdkinstall.mk b/mk/rte.sdkinstall.mk
index 0667b70..ce077a4 100644
--- a/mk/rte.sdkinstall.mk
+++ b/mk/rte.sdkinstall.mk
@@ -64,6 +64,7 @@ sbindir ?= $(exec_prefix)/sbin
libdir ?= $(exec_prefix)/lib
includedir ?= $(prefix)/include/dpdk
datarootdir ?= $(prefix)/share
+docdir ?= $(datarootdir)/doc/dpdk
datadir ?= $(datarootdir)/dpdk
sdkdir ?= $(datadir)
targetdir ?= $(datadir)/$(RTE_TARGET)
@@ -107,6 +108,7 @@ else
$(Q)$(MAKE) O=$(RTE_OUTPUT) T= install-runtime
$(Q)$(MAKE) O=$(RTE_OUTPUT) T= install-kmod
$(Q)$(MAKE) O=$(RTE_OUTPUT) T= install-sdk
+ $(Q)$(MAKE) O=$(RTE_OUTPUT) T= install-doc
@echo Installation in $(DESTDIR)$(prefix)/ complete
endif
@@ -142,3 +144,15 @@ install-sdk:
$(Q)cp -a $O/.config $(DESTDIR)$(targetdir)
$(Q)$(call rte_symlink, $(DESTDIR)$(includedir), $(DESTDIR)$(targetdir)/include)
$(Q)$(call rte_symlink, $(DESTDIR)$(libdir), $(DESTDIR)$(targetdir)/lib)
+
+install-doc:
+ifneq ($(wildcard $O/doc),)
+ $(Q)$(call rte_mkdir, $(DESTDIR)$(docdir))
+ $(Q)tar -cf - -C $O/doc html --exclude 'html/guides/.*' | \
+ tar -xf - -C $(DESTDIR)$(docdir) --strip-components=1 \
+ --keep-newer-files --warning=no-ignore-newer
+endif
+ifneq ($(wildcard $O/doc/*/*/*pdf),)
+ $(Q)$(call rte_mkdir, $(DESTDIR)$(docdir)/guides)
+ $(Q)cp -a $O/doc/*/*/*pdf $(DESTDIR)$(docdir)/guides
+endif