flow: The type of vni in VxLAN flow should be u32
[vpp.git] / docs / Makefile
1 # Minimal makefile for Sphinx documentation
2 #
3 # We support MacOS for docs generation
4 ifeq ($(shell uname),Darwin)
5 OS_ID = darwin
6 endif
7
8 # Work out the OS if we haven't already
9 OS_ID ?= $(shell grep '^ID=' /etc/os-release | cut -f2- -d= | sed -e 's/\"//g')
10
11 DOC_DEB_DEPENDS = enchant
12 DOC_RPM_DEPENDS = enchant
13
14 # You can set these variables from the command line.
15 SPHINXOPTS    =
16 SPHINXBUILD   = sphinx-build
17 SPHINXPROJ    = fdio-vpp
18 SOURCEDIR     = .
19 BUILDDIR      = _build
20
21 # Put it first so that "make" without argument is like "make help".
22 help:
23         @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
24
25 .PHONY: help Makefile
26
27 # Catch-all target: route all unknown targets to Sphinx using the new
28 # "make mode" option.  $(O) is meant as a shortcut for $(SPHINXOPTS).
29 %: Makefile
30 # Generate dynamic content
31         @python3 ./includes_renderer.py
32         @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
33
34 spell:
35         @echo "Checking whether dependencies for Docs are installed..."
36 ifeq ($(OS_ID),ubuntu)
37         @set -e; inst=; \
38                 for i in $(DOC_DEB_DEPENDS); do \
39                         dpkg-query --show $$i >/dev/null 2>&1 || inst="$$inst $$i"; \
40                 done; \
41                 if [ "$$inst" ]; then \
42                         sudo apt-get update; \
43                         sudo apt-get $(CONFIRM) $(FORCE) install $$inst; \
44                 fi
45 else ifneq ("$(wildcard /etc/redhat-release)","")
46         @sudo yum install $(CONFIRM) $(DOC_RPM_DEPENDS)
47 endif
48         @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" -W -b spelling  $(O)