Skip to content

Commit dc6b191

Browse files
committed
Doc: Add texinfo support to the Makefile
1 parent 3329cd5 commit dc6b191

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

Doc/Makefile

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ SPHINXERRORHANDLING = -W
1616
ALLSPHINXOPTS = -b $(BUILDER) -d build/doctrees -D latex_elements.papersize=$(PAPER) \
1717
$(SPHINXOPTS) $(SPHINXERRORHANDLING) . build/$(BUILDER) $(SOURCES)
1818

19-
.PHONY: help build html htmlhelp latex text changes linkcheck \
19+
.PHONY: help build html htmlhelp latex text texinfo changes linkcheck \
2020
suspicious coverage doctest pydoc-topics htmlview clean dist check serve \
2121
autobuild-dev autobuild-stable venv
2222

@@ -29,6 +29,7 @@ help:
2929
@echo " htmlhelp to make HTML files and a HTML help project"
3030
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
3131
@echo " text to make plain text files"
32+
@echo " texinfo to make Texinfo file"
3233
@echo " epub to make EPUB files"
3334
@echo " changes to make an overview over all changed/added/deprecated items"
3435
@echo " linkcheck to check all external links for integrity"
@@ -85,6 +86,11 @@ text: BUILDER = text
8586
text: build
8687
@echo "Build finished; the text files are in build/text."
8788

89+
texinfo: BUILDER = texinfo
90+
texinfo: build
91+
@echo "Build finished; the python.texi file is in build/texinfo."
92+
@echo "Run \`make info' in that directory to run it through makeinfo."
93+
8894
epub: BUILDER = epub
8995
epub: build
9096
@echo "Build finished; the epub files are in build/epub."
@@ -179,6 +185,17 @@ dist:
179185
make epub
180186
cp -pPR build/epub/Python.epub dist/python-$(DISTVERSION)-docs.epub
181187

188+
# archive the texinfo build
189+
rm -rf build/texinfo
190+
make texinfo
191+
make info --directory=build/texinfo
192+
cp -pPR build/texinfo dist/python-$(DISTVERSION)-docs-texinfo
193+
tar -C dist -cf dist/python-$(DISTVERSION)-docs-texinfo.tar python-$(DISTVERSION)-docs-texinfo
194+
bzip2 -9 -k dist/python-$(DISTVERSION)-docs-texinfo.tar
195+
(cd dist; zip -q -r -9 python-$(DISTVERSION)-docs-texinfo.zip python-$(DISTVERSION)-docs-texinfo)
196+
rm -r dist/python-$(DISTVERSION)-docs-texinfo
197+
rm dist/python-$(DISTVERSION)-docs-texinfo.tar
198+
182199
check:
183200
$(PYTHON) tools/rstlint.py -i tools -i $(VENVDIR) -i README.rst
184201

0 commit comments

Comments
 (0)