github.com/muhammedhassanm/blockchain@v0.0.0-20200120143007-697261defd4d/sawtooth-core-master/docs/Makefile (about) 1 # Makefile for Sphinx documentation 2 # 3 4 # You can set these variables from the command line. 5 SPHINXOPTS = 6 SPHINXBUILD = sphinx-build 7 SPHINXAPIDOC = sphinx-apidoc 8 PAPER = 9 BUILDDIR = build 10 11 HTMLDIR = $(BUILDDIR)/html 12 SAWTOOTH = .. 13 14 # User-friendly check for sphinx-build 15 ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $$?), 1) 16 $(error "The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/") 17 endif 18 19 # Internal variables. 20 PAPEROPT_a4 = -D latex_paper_size=a4 21 PAPEROPT_letter = -D latex_paper_size=letter 22 ALLSPHINXOPTS = -W -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source 23 # the i18n builder cannot share the environment and doctrees with the others 24 I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source 25 26 .PHONY: help clean templates html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest coverage gettext cli python go javascript 27 28 help: 29 @echo "Please use \`make <target>' where <target> is one of" 30 @echo " html to make standalone HTML files" 31 @echo " dirhtml to make HTML files named index.html in directories" 32 @echo " singlehtml to make a single large HTML file" 33 @echo " pickle to make pickle files" 34 @echo " json to make JSON files" 35 @echo " htmlhelp to make HTML files and a HTML help project" 36 @echo " qthelp to make HTML files and a qthelp project" 37 @echo " applehelp to make an Apple Help Book" 38 @echo " devhelp to make HTML files and a Devhelp project" 39 @echo " epub to make an epub" 40 @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" 41 @echo " latexpdf to make LaTeX files and run them through pdflatex" 42 @echo " latexpdfja to make LaTeX files and run them through platex/dvipdfmx" 43 @echo " text to make text files" 44 @echo " man to make manual pages" 45 @echo " texinfo to make Texinfo files" 46 @echo " info to make Texinfo files and run them through makeinfo" 47 @echo " gettext to make PO message catalogs" 48 @echo " changes to make an overview of all changed/added/deprecated items" 49 @echo " xml to make Docutils-native XML files" 50 @echo " pseudoxml to make pseudoxml-XML files for display purposes" 51 @echo " linkcheck to check all external links for integrity" 52 @echo " doctest to run all doctests embedded in the documentation (if enabled)" 53 @echo " coverage to run coverage check of the documentation (if enabled)" 54 55 clean: 56 rm -rf $(BUILDDIR)/* source/cli/output/*.out 57 58 templates: 59 @mkdir -p source/_autogen 60 @$(SAWTOOTH)/bin/make_templated_docs 61 62 cli: 63 $(SAWTOOTH)/bin/generate_cli_output 64 65 PYTHONSDKDIR := source/sdks/python_sdk 66 PYTHONAPIDOC := $(SPHINXAPIDOC) -f -o $(PYTHONSDKDIR) 67 python: 68 mkdir -p $(PYTHONSDKDIR) 69 $(PYTHONAPIDOC) ../sdk/python/sawtooth_sdk/processor 70 $(PYTHONAPIDOC) ../signing/sawtooth_signing 71 72 GOSDKDIR := $(HTMLDIR)/go_sdk 73 go: 74 mkdir -p $(GOSDKDIR) 75 godoc -html sawtooth_sdk/processor > $(GOSDKDIR)/processor.html 76 godoc -html sawtooth_sdk/signing > $(GOSDKDIR)/signing.html 77 78 JAVASCRIPTSDKDIR := $(HTMLDIR)/javascript_sdk 79 javascript: 80 mkdir -p $(JAVASCRIPTSDKDIR)/ 81 jsdoc $(SAWTOOTH)/sdk/javascript/processor/ -d $(JAVASCRIPTSDKDIR)/processor/ 82 jsdoc $(SAWTOOTH)/sdk/javascript/signing -d $(JAVASCRIPTSDKDIR)/signing/ 83 84 RUSTSDKDIR := $(HTMLDIR)/rust_sdk 85 rust: 86 mkdir -p $(RUSTSDKDIR)/ 87 cd $(SAWTOOTH)/sdk/rust/; cargo doc --no-deps --lib; 88 rm $(SAWTOOTH)/sdk/rust/target/doc/.lock 89 cp -r $(SAWTOOTH)/sdk/rust/target/doc/ $(RUSTSDKDIR)/doc 90 91 html: templates cli python go javascript rust 92 @mkdir -p source/_static 93 $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(HTMLDIR) 94 @echo 95 @echo "Build finished. The HTML pages are in $(HTMLDIR)." 96 @cp $(SAWTOOTH)/docker/compose/sawtooth-default.yaml $(HTMLDIR)/app_developers_guide/sawtooth-default.yaml 97 @cp $(SAWTOOTH)/docker/compose/sawtooth-default-poet.yaml $(HTMLDIR)/app_developers_guide/sawtooth-default-poet.yaml 98 99 dirhtml: templates cli 100 $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml 101 @echo 102 @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." 103 104 singlehtml: templates cli 105 $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml 106 @echo 107 @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." 108 109 pickle: templates cli 110 $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle 111 @echo 112 @echo "Build finished; now you can process the pickle files." 113 114 json: templates cli 115 $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json 116 @echo 117 @echo "Build finished; now you can process the JSON files." 118 119 htmlhelp: templates cli 120 $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp 121 @echo 122 @echo "Build finished; now you can run HTML Help Workshop with the" \ 123 ".hhp project file in $(BUILDDIR)/htmlhelp." 124 125 qthelp: templates cli 126 $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp 127 @echo 128 @echo "Build finished; now you can run "qcollectiongenerator" with the" \ 129 ".qhcp project file in $(BUILDDIR)/qthelp, like this:" 130 @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/IntelMaidenLane.qhcp" 131 @echo "To view the help file:" 132 @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/IntelMaidenLane.qhc" 133 134 applehelp: templates cli 135 $(SPHINXBUILD) -b applehelp $(ALLSPHINXOPTS) $(BUILDDIR)/applehelp 136 @echo 137 @echo "Build finished. The help book is in $(BUILDDIR)/applehelp." 138 @echo "N.B. You won't be able to view it unless you put it in" \ 139 "~/Library/Documentation/Help or install it in your application" \ 140 "bundle." 141 142 devhelp: templates cli 143 $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp 144 @echo 145 @echo "Build finished." 146 @echo "To view the help file:" 147 @echo "# mkdir -p $$HOME/.local/share/devhelp/IntelMaidenLane" 148 @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/IntelMaidenLane" 149 @echo "# devhelp" 150 151 epub: templates cli 152 $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub 153 @echo 154 @echo "Build finished. The epub file is in $(BUILDDIR)/epub." 155 156 latex: templates cli 157 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex 158 @echo 159 @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." 160 @echo "Run \`make' in that directory to run these through (pdf)latex" \ 161 "(use \`make latexpdf' here to do that automatically)." 162 163 latexpdf: templates cli 164 @mkdir -p source/_static 165 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex 166 @echo "Running LaTeX files through pdflatex..." 167 $(MAKE) -C $(BUILDDIR)/latex all-pdf 168 @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." 169 170 latexpdfja: templates cli 171 $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex 172 @echo "Running LaTeX files through platex and dvipdfmx..." 173 $(MAKE) -C $(BUILDDIR)/latex all-pdf-ja 174 @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." 175 176 text: templates cli 177 $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text 178 @echo 179 @echo "Build finished. The text files are in $(BUILDDIR)/text." 180 181 man: templates cli 182 $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man 183 @echo 184 @echo "Build finished. The manual pages are in $(BUILDDIR)/man." 185 186 texinfo: templates cli 187 $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo 188 @echo 189 @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." 190 @echo "Run \`make' in that directory to run these through makeinfo" \ 191 "(use \`make info' here to do that automatically)." 192 193 info: templates cli 194 $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo 195 @echo "Running Texinfo files through makeinfo..." 196 make -C $(BUILDDIR)/texinfo info 197 @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." 198 199 gettext: templates cli 200 $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale 201 @echo 202 @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale." 203 204 changes: templates cli 205 $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes 206 @echo 207 @echo "The overview file is in $(BUILDDIR)/changes." 208 209 linkcheck: templates cli 210 $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck 211 @echo 212 @echo "Link check complete; look for any errors in the above output " \ 213 "or in $(BUILDDIR)/linkcheck/output.txt." 214 215 doctest: templates cli 216 $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest 217 @echo "Testing of doctests in the sources finished, look at the " \ 218 "results in $(BUILDDIR)/doctest/output.txt." 219 220 coverage: templates cli 221 $(SPHINXBUILD) -b coverage $(ALLSPHINXOPTS) $(BUILDDIR)/coverage 222 @echo "Testing of coverage in the sources finished, look at the " \ 223 "results in $(BUILDDIR)/coverage/python.txt." 224 225 xml: templates cli 226 $(SPHINXBUILD) -b xml $(ALLSPHINXOPTS) $(BUILDDIR)/xml 227 @echo 228 @echo "Build finished. The XML files are in $(BUILDDIR)/xml." 229 230 pseudoxml: templates cli 231 $(SPHINXBUILD) -b pseudoxml $(ALLSPHINXOPTS) $(BUILDDIR)/pseudoxml 232 @echo 233 @echo "Build finished. The pseudo-XML files are in $(BUILDDIR)/pseudoxml."