[RFC PATCH 1/4] doc: add man section 3 handling
Jani Nikula
jani at nikula.org
Sun Aug 20 12:30:36 PDT 2017
We don't actually add any section 3 man pages, but be prepared.
---
doc/Makefile.local | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/doc/Makefile.local b/doc/Makefile.local
index c6f05ca879c0..04ff49b7a7fb 100644
--- a/doc/Makefile.local
+++ b/doc/Makefile.local
@@ -13,14 +13,16 @@ APIMAN := $(DOCBUILDDIR)/man/man3/notmuch.3
DOXYFILE := $(srcdir)/$(dir)/doxygen.cfg
MAN1_RST := $(wildcard $(srcdir)/doc/man1/*.rst)
+MAN3_RST := $(wildcard $(srcdir)/doc/man3/*.rst)
MAN5_RST := $(wildcard $(srcdir)/doc/man5/*.rst)
MAN7_RST := $(wildcard $(srcdir)/doc/man7/*.rst)
-MAN_RST_FILES := $(MAN1_RST) $(MAN5_RST) $(MAN7_RST)
+MAN_RST_FILES := $(MAN1_RST) $(MAN3_RST) $(MAN5_RST) $(MAN7_RST)
MAN1_ROFF := $(patsubst $(srcdir)/doc/%,$(DOCBUILDDIR)/man/%,$(MAN1_RST:.rst=.1))
+MAN3_ROFF := $(patsubst $(srcdir)/doc/%,$(DOCBUILDDIR)/man/%,$(MAN3_RST:.rst=.3))
MAN5_ROFF := $(patsubst $(srcdir)/doc/%,$(DOCBUILDDIR)/man/%,$(MAN5_RST:.rst=.5))
MAN7_ROFF := $(patsubst $(srcdir)/doc/%,$(DOCBUILDDIR)/man/%,$(MAN7_RST:.rst=.7))
-MAN_ROFF_FILES := $(MAN1_ROFF) $(MAN5_ROFF) $(MAN7_ROFF)
+MAN_ROFF_FILES := $(MAN1_ROFF) $(MAN3_ROFF) $(MAN5_ROFF) $(MAN7_ROFF)
MAN_GZIP_FILES := $(addsuffix .gz,${MAN_ROFF_FILES})
@@ -51,7 +53,7 @@ ${MAN_ROFF_FILES}: $(DOCBUILDDIR)/.roff.stamp
$(DOCBUILDDIR)/.roff.stamp: ${MAN_RST_FILES}
ifeq ($(HAVE_SPHINX),1)
$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(DOCBUILDDIR)/man
- for section in 1 5 7; do \
+ for section in 1 3 5 7; do \
mkdir -p $(DOCBUILDDIR)/man/man$${section}; \
mv $(DOCBUILDDIR)/man/*.$${section} $(DOCBUILDDIR)/man/man$${section}; \
done
@@ -90,9 +92,11 @@ else
build-man: ${MAN_GZIP_FILES}
install-man: ${MAN_GZIP_FILES}
mkdir -p "$(DESTDIR)$(mandir)/man1"
+ mkdir -p "$(DESTDIR)$(mandir)/man3"
mkdir -p "$(DESTDIR)$(mandir)/man5"
mkdir -p "$(DESTDIR)$(mandir)/man7"
install -m0644 $(filter %.1.gz,$(MAN_GZIP_FILES)) $(DESTDIR)/$(mandir)/man1
+ install -m0644 $(filter %.3.gz,$(MAN_GZIP_FILES)) $(DESTDIR)/$(mandir)/man3
install -m0644 $(filter %.5.gz,$(MAN_GZIP_FILES)) $(DESTDIR)/$(mandir)/man5
install -m0644 $(filter %.7.gz,$(MAN_GZIP_FILES)) $(DESTDIR)/$(mandir)/man7
cd $(DESTDIR)/$(mandir)/man1 && ln -sf notmuch.1.gz notmuch-setup.1.gz
--
2.11.0
More information about the notmuch
mailing list