Makefile.sphinx 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. # Makefile for Sphinx documentation
  2. #
  3. # FIXME: This hack is only in place to allow the libcxx.llvm.org/docs builder
  4. # to work with libcxx. This should be removed when that builder supports
  5. # out-of-tree builds.
  6. # You can set these variables from the command line.
  7. SPHINXOPTS = -n -W -v
  8. SPHINXBUILD = sphinx-build
  9. PAPER =
  10. BUILDDIR = _build
  11. # Internal variables.
  12. PAPEROPT_a4 = -D latex_paper_size=a4
  13. PAPEROPT_letter = -D latex_paper_size=letter
  14. ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
  15. # the i18n builder cannot share the environment and doctrees with the others
  16. I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
  17. .PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext default
  18. default: html
  19. help:
  20. @echo "Please use \`make <target>' where <target> is one of"
  21. @echo " html to make standalone HTML files"
  22. clean:
  23. -rm -rf $(BUILDDIR)/*
  24. html:
  25. $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
  26. @echo
  27. @# FIXME: Remove this `cp` once HTML->Sphinx transition is completed.
  28. @# Kind of a hack, but HTML-formatted docs are on the way out anyway.
  29. @echo "Build finished. The HTML pages are in $(BUILDDIR)/html."