vici: Update Python build
Directly calling setup.py is deprecated (apparently has been for a while, but now we get large warnings). Direct installation is also discouraged. So this removes that option. The built wheel (the old egg format is not used/built anymore) can be installed manually in a venv or the like.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
.eggs
|
||||
.tox
|
||||
*.pyc
|
||||
build
|
||||
|
||||
@@ -16,29 +16,14 @@ $(srcdir)/setup.py: $(srcdir)/setup.py.in $(top_builddir)/config.status
|
||||
-e "s:@EGG_VERSION@:$(PYTHON_PACKAGE_VERSION):" \
|
||||
$(srcdir)/setup.py.in > $@
|
||||
|
||||
all-local: dist/vici-$(PYTHON_PACKAGE_VERSION)-py$(PYTHON_VERSION).egg
|
||||
all-local: dist/vici-$(PYTHON_PACKAGE_VERSION)-py3-none-any.whl
|
||||
|
||||
dist/vici-$(PYTHON_PACKAGE_VERSION)-py$(PYTHON_VERSION).egg: $(EXTRA_DIST) $(srcdir)/setup.py
|
||||
(cd $(srcdir); $(PYTHON) setup.py bdist_egg \
|
||||
-b $(shell readlink -f $(builddir))/build \
|
||||
-d $(shell readlink -f $(builddir))/dist)
|
||||
|
||||
package: $(EXTRA_DIST) $(srcdir)/setup.py
|
||||
(cd $(srcdir); $(PYTHON) setup.py sdist \
|
||||
-d $(shell readlink -f $(builddir))/dist \
|
||||
bdist_wheel --universal \
|
||||
-d $(shell readlink -f $(builddir))/dist)
|
||||
dist/vici-$(PYTHON_PACKAGE_VERSION)-py3-none-any.whl: $(EXTRA_DIST) $(srcdir)/setup.py
|
||||
(cd $(srcdir); $(PYTHON) -m build -o $(abs_builddir)/dist)
|
||||
|
||||
clean-local:
|
||||
(cd $(srcdir); [ ! -f setup.py ] || $(PYTHON) setup.py clean -a)
|
||||
rm -rf $(srcdir)/setup.py $(srcdir)/vici.egg-info $(builddir)/dist
|
||||
|
||||
if PYTHON_EGGS_INSTALL
|
||||
install-exec-local: dist/vici-$(PYTHON_PACKAGE_VERSION)-py$(PYTHON_VERSION).egg
|
||||
$(EASY_INSTALL) $(PYTHONEGGINSTALLDIR) \
|
||||
dist/vici-$(PYTHON_PACKAGE_VERSION)-py$(PYTHON_VERSION).egg
|
||||
endif
|
||||
|
||||
if USE_TOX
|
||||
TESTS_ENVIRONMENT += export TOX=$(TOX);
|
||||
AM_TESTS_FD_REDIRECT = 1>&2
|
||||
@@ -48,5 +33,3 @@ endif
|
||||
if USE_PY_TEST
|
||||
TESTS = $(PY_TEST)
|
||||
endif
|
||||
|
||||
.PHONY: package
|
||||
|
||||
Reference in New Issue
Block a user