f2e307f1a7eb0d1a97e505597bc69a97eea8c4d1
[deb_dpdk.git] / debian / patches / dpdk-dev-v2-2-4-doc-rendering-and-installation-of-man-pages.patch
1 diff --git a/doc/guides/conf.py b/doc/guides/conf.py
2 index cd6a4f7..55b6b2f 100644
3 --- a/doc/guides/conf.py
4 +++ b/doc/guides/conf.py
5 @@ -105,6 +105,14 @@ class CustomLatexFormatter(LatexFormatter):
6  # Replace the default latex formatter.
7  PygmentsBridge.latex_formatter = CustomLatexFormatter
8  
9 +# Configuration for man pages
10 +man_pages = [("testpmd_app_ug/run_app", "testpmd",
11 +              "tests for dpdk pmds", "", 1),
12 +             ("tools/pdump", "dpdk-pdump",
13 +              "enable packet capture on dpdk ports", "", 1),
14 +             ("tools/proc_info", "dpdk-procinfo",
15 +              "access dpdk port stats and memory info", "", 1)]
16 +
17  ######## :numref: fallback ########
18  # The following hook functions add some simple handling for the :numref:
19  # directive for Sphinx versions prior to 1.3.1. The functions replace the
20 diff --git a/mk/rte.sdkdoc.mk b/mk/rte.sdkdoc.mk
21 index 9952f25..21d9bdf 100644
22 --- a/mk/rte.sdkdoc.mk
23 +++ b/mk/rte.sdkdoc.mk
24 @@ -63,7 +63,7 @@ help:
25  all: api-html guides-html guides-pdf
26  
27  .PHONY: clean
28 -clean: api-html-clean guides-html-clean guides-pdf-clean
29 +clean: api-html-clean guides-html-clean guides-pdf-clean guides-man-clean
30  
31  .PHONY: api-html
32  api-html: api-html-clean
33 diff --git a/mk/rte.sdkinstall.mk b/mk/rte.sdkinstall.mk
34 index 5217063..533d369 100644
35 --- a/mk/rte.sdkinstall.mk
36 +++ b/mk/rte.sdkinstall.mk
37 @@ -66,6 +66,7 @@ includedir  ?=      $(prefix)/include/dpdk
38  datarootdir ?=      $(prefix)/share
39  docdir      ?=       $(datarootdir)/doc/dpdk
40  datadir     ?=       $(datarootdir)/dpdk
41 +mandir      ?=       $(datarootdir)/man
42  sdkdir      ?=                $(datadir)
43  targetdir   ?=                $(datadir)/$(RTE_TARGET)
44  
45 @@ -133,6 +134,11 @@ install-runtime:
46                                    $(DESTDIR)$(sbindir)/dpdk-devbind)
47         $(Q)$(call rte_symlink,    $(DESTDIR)$(datadir)/tools/dpdk-pmdinfo.py, \
48                                    $(DESTDIR)$(bindir)/dpdk-pmdinfo)
49 +ifneq ($(wildcard $O/doc/man/*/*.1),)
50 +       $(Q)$(call rte_mkdir,     $(DESTDIR)$(mandir))
51 +       $(Q)$(call rte_mkdir,     $(DESTDIR)$(mandir)/man1)
52 +       $(Q)cp -a $O/doc/man/*/*.1 $(DESTDIR)$(mandir)/man1
53 +endif
54  
55  install-kmod:
56  ifneq ($(wildcard $O/kmod/*),)