Show More
@@ -1,165 +1,165 | |||||
1 | # Makefile for Sphinx documentation |
|
1 | # Makefile for Sphinx documentation | |
2 | # |
|
2 | # | |
3 |
|
3 | |||
4 | # You can set these variables from the command line. |
|
4 | # You can set these variables from the command line. | |
5 | SPHINXOPTS = |
|
5 | SPHINXOPTS = | |
6 | SPHINXBUILD = sphinx-build |
|
6 | SPHINXBUILD = sphinx-build | |
7 | PAPER = |
|
7 | PAPER = | |
8 | SRCDIR = source |
|
8 | SRCDIR = source | |
9 | BUILDDIR = build |
|
9 | BUILDDIR = build | |
10 |
|
10 | |||
11 | # Internal variables. |
|
11 | # Internal variables. | |
12 | PAPEROPT_a4 = -D latex_paper_size=a4 |
|
12 | PAPEROPT_a4 = -D latex_paper_size=a4 | |
13 | PAPEROPT_letter = -D latex_paper_size=letter |
|
13 | PAPEROPT_letter = -D latex_paper_size=letter | |
14 | ALLSPHINXOPTS = -d build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) $(SRCDIR) |
|
14 | ALLSPHINXOPTS = -d build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) $(SRCDIR) | |
15 |
|
15 | |||
16 | .PHONY: help clean html web pickle htmlhelp latex changes linkcheck api |
|
16 | .PHONY: help clean html web pickle htmlhelp latex changes linkcheck api | |
17 |
|
17 | |||
18 | default: html |
|
18 | default: html | |
19 |
|
19 | |||
20 | help: |
|
20 | help: | |
21 | @echo "Please use \`make <target>' where <target> is one of" |
|
21 | @echo "Please use \`make <target>' where <target> is one of" | |
22 | @echo " html standalone HTML files" |
|
22 | @echo " html standalone HTML files" | |
23 | @echo " html_noapi same as above, without the time consuming API docs" |
|
23 | @echo " html_noapi same as above, without the time consuming API docs" | |
24 | @echo " pickle pickle files (usable by e.g. sphinx-web)" |
|
24 | @echo " pickle pickle files (usable by e.g. sphinx-web)" | |
25 | @echo " htmlhelp HTML files and a HTML help project" |
|
25 | @echo " htmlhelp HTML files and a HTML help project" | |
26 | @echo " latex LaTeX files, you can set PAPER=a4 or PAPER=letter" |
|
26 | @echo " latex LaTeX files, you can set PAPER=a4 or PAPER=letter" | |
27 | @echo " texinfo Texinfo files" |
|
27 | @echo " texinfo Texinfo files" | |
28 | @echo " info Texinfo files and run them through makeinfo" |
|
28 | @echo " info Texinfo files and run them through makeinfo" | |
29 | @echo " changes an overview over all changed/added/deprecated items" |
|
29 | @echo " changes an overview over all changed/added/deprecated items" | |
30 | @echo " linkcheck check all external links for integrity (takes a long time)" |
|
30 | @echo " linkcheck check all external links for integrity (takes a long time)" | |
31 | @echo |
|
31 | @echo | |
32 | @echo "Compound utility targets:" |
|
32 | @echo "Compound utility targets:" | |
33 | @echo "pdf latex and then runs the PDF generation" |
|
33 | @echo "pdf latex and then runs the PDF generation" | |
34 | @echo "all html and pdf" |
|
34 | @echo "all html and pdf" | |
35 | @echo "dist all, and then puts the results in dist/" |
|
35 | @echo "dist all, and then puts the results in dist/" | |
36 | @echo "gitwash-update update git workflow from source repo" |
|
36 | @echo "gitwash-update update git workflow from source repo" | |
37 |
|
37 | |||
38 | clean_api: |
|
38 | clean_api: | |
39 | -rm -rf $(SRCDIR)/api/generated |
|
39 | -rm -rf $(SRCDIR)/api/generated | |
40 |
|
40 | |||
41 | clean: clean_api |
|
41 | clean: clean_api | |
42 | -rm -rf build/* dist/* |
|
42 | -rm -rf build/* dist/* | |
43 |
-cd $(SRCDIR)/config/options; cat generated | xargs |
|
43 | -cd $(SRCDIR)/config/options; test -f generated && cat generated | xargs rm -f | |
44 | -rm -rf $(SRCDIR)/config/options/generated |
|
44 | -rm -rf $(SRCDIR)/config/options/generated | |
45 | -rm -f $(SRCDIR)/interactive/magics-generated.txt |
|
45 | -rm -f $(SRCDIR)/interactive/magics-generated.txt | |
46 |
|
46 | |||
47 | pdf: latex |
|
47 | pdf: latex | |
48 | cd build/latex && make all-pdf |
|
48 | cd build/latex && make all-pdf | |
49 |
|
49 | |||
50 | all: html pdf |
|
50 | all: html pdf | |
51 |
|
51 | |||
52 | # For final distribution, only build HTML (our pdf is now so large as to be |
|
52 | # For final distribution, only build HTML (our pdf is now so large as to be | |
53 | # unusable, takes forever to build and just bloats the downloads). We leave |
|
53 | # unusable, takes forever to build and just bloats the downloads). We leave | |
54 | # them hardlinked at the top-level so users find them easily, though the |
|
54 | # them hardlinked at the top-level so users find them easily, though the | |
55 | # original build/html dir is left in-place (useful to reload builds while |
|
55 | # original build/html dir is left in-place (useful to reload builds while | |
56 | # testing). |
|
56 | # testing). | |
57 | dist: html |
|
57 | dist: html | |
58 | rm -rf html |
|
58 | rm -rf html | |
59 | cp -al build/html . |
|
59 | cp -al build/html . | |
60 | @echo "Build finished. Final docs are in html/" |
|
60 | @echo "Build finished. Final docs are in html/" | |
61 |
|
61 | |||
62 | html: jsapi api autoconfig automagic |
|
62 | html: jsapi api autoconfig automagic | |
63 | html_noapi: clean_api autoconfig automagic |
|
63 | html_noapi: clean_api autoconfig automagic | |
64 |
|
64 | |||
65 | html html_noapi: |
|
65 | html html_noapi: | |
66 | mkdir -p build/html build/doctrees |
|
66 | mkdir -p build/html build/doctrees | |
67 | $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) build/html |
|
67 | $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) build/html | |
68 | @echo |
|
68 | @echo | |
69 | @echo "Build finished. The HTML pages are in build/html." |
|
69 | @echo "Build finished. The HTML pages are in build/html." | |
70 |
|
70 | |||
71 | automagic: source/interactive/magics-generated.txt |
|
71 | automagic: source/interactive/magics-generated.txt | |
72 |
|
72 | |||
73 | source/interactive/magics-generated.txt: autogen_magics.py |
|
73 | source/interactive/magics-generated.txt: autogen_magics.py | |
74 | python autogen_magics.py |
|
74 | python autogen_magics.py | |
75 | @echo "Created docs for line & cell magics" |
|
75 | @echo "Created docs for line & cell magics" | |
76 |
|
76 | |||
77 | autoconfig: source/config/options/generated |
|
77 | autoconfig: source/config/options/generated | |
78 |
|
78 | |||
79 | source/config/options/generated: |
|
79 | source/config/options/generated: | |
80 | python autogen_config.py |
|
80 | python autogen_config.py | |
81 | @echo "Created docs for config options" |
|
81 | @echo "Created docs for config options" | |
82 |
|
82 | |||
83 | jsapi: |
|
83 | jsapi: | |
84 | jsdoc -c jsdoc_config.json -d ./build/jsapi_html/ |
|
84 | jsdoc -c jsdoc_config.json -d ./build/jsapi_html/ | |
85 |
|
85 | |||
86 | api: source/api/generated/gen.txt |
|
86 | api: source/api/generated/gen.txt | |
87 |
|
87 | |||
88 | source/api/generated/gen.txt: |
|
88 | source/api/generated/gen.txt: | |
89 | python autogen_api.py |
|
89 | python autogen_api.py | |
90 | @echo "Build API docs finished." |
|
90 | @echo "Build API docs finished." | |
91 |
|
91 | |||
92 | pickle: |
|
92 | pickle: | |
93 | mkdir -p build/pickle build/doctrees |
|
93 | mkdir -p build/pickle build/doctrees | |
94 | $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) build/pickle |
|
94 | $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) build/pickle | |
95 | @echo |
|
95 | @echo | |
96 | @echo "Build finished; now you can process the pickle files or run" |
|
96 | @echo "Build finished; now you can process the pickle files or run" | |
97 | @echo " sphinx-web build/pickle" |
|
97 | @echo " sphinx-web build/pickle" | |
98 | @echo "to start the sphinx-web server." |
|
98 | @echo "to start the sphinx-web server." | |
99 |
|
99 | |||
100 | web: pickle |
|
100 | web: pickle | |
101 |
|
101 | |||
102 | htmlhelp: |
|
102 | htmlhelp: | |
103 | mkdir -p build/htmlhelp build/doctrees |
|
103 | mkdir -p build/htmlhelp build/doctrees | |
104 | $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) build/htmlhelp |
|
104 | $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) build/htmlhelp | |
105 | @echo |
|
105 | @echo | |
106 | @echo "Build finished; now you can run HTML Help Workshop with the" \ |
|
106 | @echo "Build finished; now you can run HTML Help Workshop with the" \ | |
107 | ".hhp project file in build/htmlhelp." |
|
107 | ".hhp project file in build/htmlhelp." | |
108 |
|
108 | |||
109 | qthelp: |
|
109 | qthelp: | |
110 | mkdir -p build/qthelp |
|
110 | mkdir -p build/qthelp | |
111 | $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) build/qthelp |
|
111 | $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) build/qthelp | |
112 | @echo |
|
112 | @echo | |
113 | @echo "Build finished; now you can run "qcollectiongenerator" with the" \ |
|
113 | @echo "Build finished; now you can run "qcollectiongenerator" with the" \ | |
114 | ".qhcp project file in $(BUILDDIR)/qthelp, like this:" |
|
114 | ".qhcp project file in $(BUILDDIR)/qthelp, like this:" | |
115 | @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/IPython.qhcp" |
|
115 | @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/IPython.qhcp" | |
116 | @echo "To view the help file:" |
|
116 | @echo "To view the help file:" | |
117 | @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/IPython.qhc" |
|
117 | @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/IPython.qhc" | |
118 |
|
118 | |||
119 | latex: api autoconfig |
|
119 | latex: api autoconfig | |
120 | mkdir -p build/latex build/doctrees |
|
120 | mkdir -p build/latex build/doctrees | |
121 | $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) build/latex |
|
121 | $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) build/latex | |
122 | @echo |
|
122 | @echo | |
123 | @echo "Build finished; the LaTeX files are in build/latex." |
|
123 | @echo "Build finished; the LaTeX files are in build/latex." | |
124 | @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \ |
|
124 | @echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \ | |
125 | "run these through (pdf)latex." |
|
125 | "run these through (pdf)latex." | |
126 |
|
126 | |||
127 | changes: |
|
127 | changes: | |
128 | mkdir -p build/changes build/doctrees |
|
128 | mkdir -p build/changes build/doctrees | |
129 | $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) build/changes |
|
129 | $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) build/changes | |
130 | @echo |
|
130 | @echo | |
131 | @echo "The overview file is in build/changes." |
|
131 | @echo "The overview file is in build/changes." | |
132 |
|
132 | |||
133 | linkcheck: |
|
133 | linkcheck: | |
134 | mkdir -p build/linkcheck build/doctrees |
|
134 | mkdir -p build/linkcheck build/doctrees | |
135 | $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) build/linkcheck |
|
135 | $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) build/linkcheck | |
136 | @echo |
|
136 | @echo | |
137 | @echo "Link check complete; look for any errors in the above output " \ |
|
137 | @echo "Link check complete; look for any errors in the above output " \ | |
138 | "or in build/linkcheck/output.rst." |
|
138 | "or in build/linkcheck/output.rst." | |
139 |
|
139 | |||
140 | gitwash-update: |
|
140 | gitwash-update: | |
141 | python ../tools/gitwash_dumper.py source/development ipython |
|
141 | python ../tools/gitwash_dumper.py source/development ipython | |
142 |
|
142 | |||
143 | nightly: dist |
|
143 | nightly: dist | |
144 | rsync -avH --delete dist/ ipython:www/doc/nightly |
|
144 | rsync -avH --delete dist/ ipython:www/doc/nightly | |
145 |
|
145 | |||
146 | gh-pages: clean html |
|
146 | gh-pages: clean html | |
147 | # if VERSION is unspecified, it will be dev |
|
147 | # if VERSION is unspecified, it will be dev | |
148 | # For releases, VERSION should be just the major version, |
|
148 | # For releases, VERSION should be just the major version, | |
149 | # e.g. VERSION=2 make gh-pages |
|
149 | # e.g. VERSION=2 make gh-pages | |
150 | python gh-pages.py $(VERSION) |
|
150 | python gh-pages.py $(VERSION) | |
151 |
|
151 | |||
152 | texinfo: |
|
152 | texinfo: | |
153 | mkdir -p $(BUILDDIR)/texinfo |
|
153 | mkdir -p $(BUILDDIR)/texinfo | |
154 | $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo |
|
154 | $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo | |
155 | @echo |
|
155 | @echo | |
156 | @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." |
|
156 | @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." | |
157 | @echo "Run \`make' in that directory to run these through makeinfo" \ |
|
157 | @echo "Run \`make' in that directory to run these through makeinfo" \ | |
158 | "(use \`make info' here to do that automatically)." |
|
158 | "(use \`make info' here to do that automatically)." | |
159 |
|
159 | |||
160 | info: |
|
160 | info: | |
161 | mkdir -p $(BUILDDIR)/texinfo |
|
161 | mkdir -p $(BUILDDIR)/texinfo | |
162 | $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo |
|
162 | $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo | |
163 | @echo "Running Texinfo files through makeinfo..." |
|
163 | @echo "Running Texinfo files through makeinfo..." | |
164 | make -C $(BUILDDIR)/texinfo info |
|
164 | make -C $(BUILDDIR)/texinfo info | |
165 | @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." |
|
165 | @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." |
General Comments 0
You need to be logged in to leave comments.
Login now