]> git.proxmox.com Git - mirror_qemu.git/blob - python/Makefile
Merge remote-tracking branch 'remotes/thuth-gitlab/tags/pull-request-2021-06-02'...
[mirror_qemu.git] / python / Makefile
1 .PHONY: help venv venv-check check clean distclean develop
2
3 help:
4 @echo "python packaging help:"
5 @echo ""
6 @echo "make venv: Create pipenv's virtual environment."
7 @echo " NOTE: Requires Python 3.6 and pipenv."
8 @echo " Will download packages from PyPI."
9 @echo " Hint: (On Fedora): 'sudo dnf install python36 pipenv'"
10 @echo ""
11 @echo "make venv-check: run linters using pipenv's virtual environment."
12 @echo " Hint: If you don't know which test to run, run this one!"
13 @echo ""
14 @echo "make develop: Install deps for 'make check', and"
15 @echo " the qemu libs in editable/development mode."
16 @echo ""
17 @echo "make check: run linters using the current environment."
18 @echo ""
19 @echo "make check-tox: run linters using multiple python versions."
20 @echo ""
21 @echo "make clean: remove package build output."
22 @echo ""
23 @echo "make distclean: remove venv files, qemu package forwarder,"
24 @echo " built distribution files, and everything"
25 @echo " from 'make clean'."
26
27 venv: .venv
28 .venv: Pipfile.lock
29 @PIPENV_VENV_IN_PROJECT=1 pipenv sync --dev --keep-outdated
30 @touch .venv
31
32 venv-check: venv
33 @pipenv run make check
34
35 develop:
36 pip3 install -e .[devel]
37
38 check:
39 @avocado --config avocado.cfg run tests/
40
41 check-tox:
42 @tox
43
44 clean:
45 python3 setup.py clean --all
46
47 distclean: clean
48 rm -rf qemu.egg-info/ .venv/ .tox/ dist/