[2] | 1 | #+ |
---|
| 2 | # |
---|
| 3 | # .. _Makefile: |
---|
| 4 | # |
---|
| 5 | # ======== |
---|
| 6 | # Makefile |
---|
| 7 | # ======== |
---|
| 8 | # |
---|
| 9 | # DESCRIPTION |
---|
| 10 | # =========== |
---|
| 11 | # |
---|
| 12 | # Makefile for Sphinx documentation |
---|
| 13 | # |
---|
| 14 | # SEE ALSO |
---|
| 15 | # ======== |
---|
| 16 | # |
---|
| 17 | # :ref:`builddoc` |
---|
| 18 | # |
---|
| 19 | # :ref:`makefile_non_sphinx` |
---|
| 20 | # |
---|
| 21 | # TODO |
---|
| 22 | # ==== |
---|
| 23 | # |
---|
| 24 | # moins bourrin dans l'usage de makefile_non_sphinx et la génération du |
---|
| 25 | # logo |
---|
| 26 | # |
---|
| 27 | # |
---|
| 28 | # EVOLUTIONS |
---|
| 29 | # ========== |
---|
| 30 | # |
---|
| 31 | # $Id: Makefile 30 2012-03-13 10:53:33Z pinsard $ |
---|
| 32 | # |
---|
| 33 | # $URL: svn+ssh://pinsard@forge.ipsl.jussieu.fr/ipsl/forge/projets/fptools/svn/trunk/docs/docs_dev/Makefile $ |
---|
| 34 | # |
---|
| 35 | # - fplod 20120424 |
---|
| 36 | # |
---|
| 37 | # * creation |
---|
| 38 | # |
---|
| 39 | #- |
---|
| 40 | |
---|
| 41 | # |
---|
| 42 | # You can set these variables from the command line. |
---|
| 43 | SPHINXOPTS = |
---|
| 44 | SPHINXBUILD = sphinx-build |
---|
| 45 | PAPER = |
---|
| 46 | BUILDDIR = ../../doc/ |
---|
| 47 | |
---|
| 48 | # Internal variables. |
---|
| 49 | PAPEROPT_a4 = -D latex_paper_size=a4 |
---|
| 50 | PAPEROPT_letter = -D latex_paper_size=letter |
---|
| 51 | ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source |
---|
| 52 | |
---|
| 53 | .PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest |
---|
| 54 | |
---|
| 55 | help: |
---|
| 56 | @echo "Please use \`make <target>' where <target> is one of" |
---|
| 57 | @echo "Please use \`make <target>' where <target> is one of" |
---|
| 58 | @echo " html to make standalone HTML files" |
---|
| 59 | @echo " dirhtml to make HTML files named index.html in directories" |
---|
| 60 | @echo " singlehtml to make a single large HTML file" |
---|
| 61 | @echo " pickle to make pickle files" |
---|
| 62 | @echo " json to make JSON files" |
---|
| 63 | @echo " htmlhelp to make HTML files and a HTML help project" |
---|
| 64 | @echo " qthelp to make HTML files and a qthelp project" |
---|
| 65 | @echo " devhelp to make HTML files and a Devhelp project" |
---|
| 66 | @echo " epub to make an epub" |
---|
| 67 | @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" |
---|
| 68 | @echo " latexpdf to make LaTeX files and run them through pdflatex" |
---|
| 69 | @echo " text to make text files" |
---|
| 70 | @echo " man to make manual pages" |
---|
| 71 | @echo " changes to make an overview of all changed/added/deprecated items" |
---|
| 72 | @echo " linkcheck to check all external links for integrity" |
---|
| 73 | @echo " doctest to run all doctests embedded in the documentation (if enabled)" |
---|
| 74 | |
---|
| 75 | clean: |
---|
| 76 | @make -f makefile_non_sphinx clean |
---|
| 77 | -rm -rf $(BUILDDIR)/* |
---|
| 78 | |
---|
| 79 | html: |
---|
| 80 | @make -f makefile_non_sphinx all |
---|
| 81 | $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html |
---|
| 82 | @echo |
---|
| 83 | @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." |
---|
| 84 | |
---|
| 85 | dirhtml: |
---|
| 86 | @make -f makefile_non_sphinx all |
---|
| 87 | $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml |
---|
| 88 | @echo |
---|
| 89 | @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." |
---|
| 90 | |
---|
| 91 | singlehtml: |
---|
| 92 | @make -f makefile_non_sphinx all |
---|
| 93 | $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml |
---|
| 94 | @echo |
---|
| 95 | @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." |
---|
| 96 | |
---|
| 97 | pickle: |
---|
| 98 | @make -f makefile_non_sphinx all |
---|
| 99 | $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle |
---|
| 100 | @echo |
---|
| 101 | @echo "Build finished; now you can process the pickle files." |
---|
| 102 | |
---|
| 103 | json: |
---|
| 104 | @make -f makefile_non_sphinx all |
---|
| 105 | $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json |
---|
| 106 | @echo |
---|
| 107 | @echo "Build finished; now you can process the JSON files." |
---|
| 108 | |
---|
| 109 | htmlhelp: |
---|
| 110 | @make -f makefile_non_sphinx all |
---|
| 111 | $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp |
---|
| 112 | @echo |
---|
| 113 | @echo "Build finished; now you can run HTML Help Workshop with the" \ |
---|
| 114 | ".hhp project file in $(BUILDDIR)/htmlhelp." |
---|
| 115 | |
---|
| 116 | qthelp: |
---|
| 117 | @make -f makefile_non_sphinx all |
---|
| 118 | $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp |
---|
| 119 | @echo |
---|
| 120 | @echo "Build finished; now you can run "qcollectiongenerator" with the" \ |
---|
| 121 | ".qhcp project file in $(BUILDDIR)/qthelp, like this:" |
---|
| 122 | @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/VARAMMA.qhcp" |
---|
| 123 | @echo "To view the help file:" |
---|
| 124 | @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/VARAMMA.qhc" |
---|
| 125 | devhelp: |
---|
| 126 | @make -f makefile_non_sphinx all |
---|
| 127 | $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp |
---|
| 128 | @echo |
---|
| 129 | @echo "Build finished." |
---|
| 130 | @echo "To view the help file:" |
---|
| 131 | @echo "# mkdir -p $$HOME/.local/share/devhelp/TROPFLUX" |
---|
| 132 | @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/TROPFLUX" |
---|
| 133 | @echo "# devhelp" |
---|
| 134 | |
---|
| 135 | epub: |
---|
| 136 | @make -f makefile_non_sphinx all |
---|
| 137 | $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub |
---|
| 138 | @echo |
---|
| 139 | @echo "Build finished. The epub file is in $(BUILDDIR)/epub." |
---|
| 140 | |
---|
| 141 | latex: |
---|
| 142 | @make -f makefile_non_sphinx all |
---|
| 143 | $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex |
---|
| 144 | @echo |
---|
| 145 | @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." |
---|
| 146 | @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \ |
---|
| 147 | "run these through (pdf)latex." |
---|
| 148 | |
---|
| 149 | latexpdf: |
---|
| 150 | @make -f makefile_non_sphinx all |
---|
| 151 | $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex |
---|
| 152 | @echo "Running LaTeX files through pdflatex..." |
---|
| 153 | make -C $(BUILDDIR)/latex all-pdf |
---|
| 154 | @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." |
---|
| 155 | |
---|
| 156 | text: |
---|
| 157 | @make -f makefile_non_sphinx all |
---|
| 158 | $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text |
---|
| 159 | @echo |
---|
| 160 | @echo "Build finished. The text files are in $(BUILDDIR)/text." |
---|
| 161 | |
---|
| 162 | man: |
---|
| 163 | @make -f makefile_non_sphinx all |
---|
| 164 | $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man |
---|
| 165 | @echo |
---|
| 166 | @echo "Build finished. The manual pages are in $(BUILDDIR)/man." |
---|
| 167 | |
---|
| 168 | changes: |
---|
| 169 | @make -f makefile_non_sphinx all |
---|
| 170 | $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes |
---|
| 171 | @echo |
---|
| 172 | @echo "The overview file is in $(BUILDDIR)/changes." |
---|
| 173 | |
---|
| 174 | linkcheck: |
---|
| 175 | @make -f makefile_non_sphinx all |
---|
| 176 | $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck |
---|
| 177 | @echo |
---|
| 178 | @echo "Link check complete; look for any errors in the above output " \ |
---|
| 179 | "or in $(BUILDDIR)/linkcheck/output.txt." |
---|
| 180 | |
---|
| 181 | doctest: |
---|
| 182 | @make -f makefile_non_sphinx all |
---|
| 183 | $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest |
---|
| 184 | @echo "Testing of doctests in the sources finished, look at the " \ |
---|
| 185 | "results in $(BUILDDIR)/doctest/output.txt." |
---|