summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-02-09 15:37:35 -0500
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-02-22 16:57:43 +0100
commit9015fa646e04fc3cb180bea24c33d34edbb48ed7 (patch)
tree11d994d2046f2cb6043add66bc58d57603497836 /Makefile.am
parentd489071fb348cd180bc4f70e732b0e76d9804448 (diff)
python: build html docs using sphinx
Build instructions: make make DESTIDIR=/tmp/... install make DESTIDIR=/tmp/... sphinx-html sphinx-man sphinx-epub ...
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am8
1 files changed, 8 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am
index 42d35441ea..085f4b36b2 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -3433,6 +3433,14 @@ BUILT_SOURCES += \
src/python-systemd/id128-constants.h
endif
+if ENABLE_SPHINX
+PAPER = $(shell cat /etc/papersize 2>/dev/null || echo a4)
+SPHINXOPTS = -D latex_paper_size=$(PAPER)
+sphinx-%:
+ $(AM_V_GEN)PYTHONPATH=$(DESTDIR)$(pyexecdir) $(SPHINX_BUILD) -b $* $(SPHINXOPTS) $(top_srcdir)/src/python-systemd/docs $(top_builddir)/man/python-systemd/
+ $(AM_V_at)echo Output has been generated in $(abs_top_builddir)/man/python-systemd/
+endif
+
# ------------------------------------------------------------------------------
SED_PROCESS = \
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \