xref: /petsc/doc/makefile (revision a4af0ceea8a251db97ee0dc5c0d52d4adf50264a)
1# Initially generated with sphinx-quickstart
2
3# You can set these variables from the command line, and also
4# from the environment for the first two.
5SPHINXOPTS    ?=
6SPHINXBUILD   ?= sphinx-build
7SOURCEDIR     = .
8BUILDDIR      = _build
9LINKCHECKDIR  = _build/linkcheck
10
11# First so that "make" without arguments is like "make help".
12help:
13	@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS)
14
15.PHONY: help makefile checklinks
16
17checklinks:
18	@$(SPHINXBUILD) -b linkcheck "$(SOURCEDIR)" "$(LINKCHECKDIR)" $(SPHINXOPTS)
19	@echo
20	@echo "Check finished. Report is in $(LINKCHECKDIR)."
21
22clean-classic-docs:
23	./build_classic_docs.py --clean
24
25clean: clean-classic-docs
26
27images:
28	git clone https://gitlab.com/petsc/images.git -b main-1 --depth=1 images
29
30website-deploy: images
31	$(SPHINXBUILD) -b dirhtml "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) -T -E -j auto
32
33# Catch-all target: route all unknown targets to Sphinx using the new
34# "make mode" option.
35%: makefile images
36	@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) -j auto
37
38