From: Luke Kenneth Casson Leighton Date: Fri, 23 Apr 2021 12:54:20 +0000 (+0100) Subject: add Makefile X-Git-Tag: 0.0.1~40 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=81adbbd18060ddf58c47584df87c4705d42b5d30;p=openpower-isa.git add Makefile --- diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..04db8f2d --- /dev/null +++ b/Makefile @@ -0,0 +1,48 @@ +PYTHON3 ?= "python3" + +.PHONY: help Makefile gitupdate svanalysis test htmlupload pypiuload + +gitupdate: + git submodule init + git submodule update --init --recursive --remote + +svanalysis: + python3 openpower/sv_analysis.py + +develop: + python3 setup.py develop # yes, develop, not install + +# testing (usually done at install time) +test: develop + python3 setup.py test # could just run nosetest3... + +pypiupload: + $(PYTHON3) setup.py sdist upload + +# Minimal makefile for Sphinx documentation +# + +# You can set these variables from the command line. +SPHINXOPTS = +SPHINXBUILD = sphinx-build +SPHINXPROJ = Libre-SOC +SOURCEDIR = . +BUILDDIR = build + +# Put it first so that "make" without argument is like "make help". +help: + @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + +# copies all documentation to libre-soc (libre-soc admins only) +htmlupload: clean html + rsync -HPavz --delete build/html/* \ + libre-soc.org:/var/www/libre-soc.org/docs/soc/ + +# Catch-all target: route all unknown targets to Sphinx using the new +# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). +%: Makefile + echo "catch-all falling through to sphinx for document building" + mkdir -p "$(SOURCEDIR)"/src/gen + sphinx-apidoc --ext-autodoc -o "$(SOURCEDIR)"/src/gen ./src/soc + @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) +