aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--dev-vcs/dandi-cli/dandi-cli-0.37.0.ebuild2
-rw-r--r--dev-vcs/dandi-cli/dandi-cli-0.38.0.ebuild2
-rw-r--r--dev-vcs/dandi-cli/dandi-cli-0.39.4.ebuild5
-rw-r--r--dev-vcs/dandi-cli/files/dandi-cli-0.37.0-pep517.patch46
4 files changed, 54 insertions, 1 deletions
diff --git a/dev-vcs/dandi-cli/dandi-cli-0.37.0.ebuild b/dev-vcs/dandi-cli/dandi-cli-0.37.0.ebuild
index e1117b65e..08d652de9 100644
--- a/dev-vcs/dandi-cli/dandi-cli-0.37.0.ebuild
+++ b/dev-vcs/dandi-cli/dandi-cli-0.37.0.ebuild
@@ -3,6 +3,7 @@
EAPI=8
+DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{8..10} )
inherit distutils-r1
@@ -67,6 +68,7 @@ distutils_enable_tests pytest
PATCHES=(
"${FILESDIR}/${PN}-0.37.0-pip-versioncheck.patch"
+ "${FILESDIR}/${PN}-0.37.0-pep517.patch"
)
src_prepare() {
diff --git a/dev-vcs/dandi-cli/dandi-cli-0.38.0.ebuild b/dev-vcs/dandi-cli/dandi-cli-0.38.0.ebuild
index e1117b65e..08d652de9 100644
--- a/dev-vcs/dandi-cli/dandi-cli-0.38.0.ebuild
+++ b/dev-vcs/dandi-cli/dandi-cli-0.38.0.ebuild
@@ -3,6 +3,7 @@
EAPI=8
+DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{8..10} )
inherit distutils-r1
@@ -67,6 +68,7 @@ distutils_enable_tests pytest
PATCHES=(
"${FILESDIR}/${PN}-0.37.0-pip-versioncheck.patch"
+ "${FILESDIR}/${PN}-0.37.0-pep517.patch"
)
src_prepare() {
diff --git a/dev-vcs/dandi-cli/dandi-cli-0.39.4.ebuild b/dev-vcs/dandi-cli/dandi-cli-0.39.4.ebuild
index 1f68c40bf..11f322912 100644
--- a/dev-vcs/dandi-cli/dandi-cli-0.39.4.ebuild
+++ b/dev-vcs/dandi-cli/dandi-cli-0.39.4.ebuild
@@ -3,6 +3,7 @@
EAPI=8
+DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{8..10} )
inherit distutils-r1
@@ -39,11 +40,12 @@ RDEPEND="
dev-python/ruamel-yaml[${PYTHON_USEDEP}]
dev-python/semantic_version[${PYTHON_USEDEP}]
dev-python/tenacity[${PYTHON_USEDEP}]
+ dev-python/versioneer[${PYTHON_USEDEP}]
dev-python/wheel[${PYTHON_USEDEP}]
dev-python/zarr[${PYTHON_USEDEP}]
"
-DEPEND="
+BDEPEND="
test? (
dev-python/anys[${PYTHON_USEDEP}]
dev-python/responses[${PYTHON_USEDEP}]
@@ -68,6 +70,7 @@ distutils_enable_tests pytest
PATCHES=(
"${FILESDIR}/${PN}-0.37.0-pip-versioncheck.patch"
+ "${FILESDIR}/${PN}-0.37.0-pep517.patch"
)
src_prepare() {
diff --git a/dev-vcs/dandi-cli/files/dandi-cli-0.37.0-pep517.patch b/dev-vcs/dandi-cli/files/dandi-cli-0.37.0-pep517.patch
new file mode 100644
index 000000000..4d4715f95
--- /dev/null
+++ b/dev-vcs/dandi-cli/files/dandi-cli-0.37.0-pep517.patch
@@ -0,0 +1,46 @@
+From a363b68b79b3dd2004912640c90958882a918537 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
+Date: Wed, 4 May 2022 19:49:37 +0200
+Subject: [PATCH] Prepend to sys.path to fix versioneer in PEP517 mode
+
+Prepend the current directory to sys.path rather than appending it
+in order to fix the build in PEP517 mode properly. If the path
+is appended and versioneer is installed on the system, the system
+versioneer.py (i.e. the module used to install versioneer into projects)
+is imported rather than the local file, and the build fails:
+
+```
+Traceback (most recent call last):
+ File "/usr/lib/python-exec/python3.10/gpep517", line 4, in <module>
+ sys.exit(main())
+ File "/usr/lib/python3.10/site-packages/gpep517/__main__.py", line 136, in main
+ return func(args)
+ File "/usr/lib/python3.10/site-packages/gpep517/__main__.py", line 44, in build_wheel
+ wheel_name = backend.build_wheel(args.wheel_dir, args.config_json)
+ File "/usr/lib/python3.10/site-packages/setuptools/build_meta.py", line 244, in build_wheel
+ return self._build_with_temp_dir(['bdist_wheel'], '.whl',
+ File "/usr/lib/python3.10/site-packages/setuptools/build_meta.py", line 229, in _build_with_temp_dir
+ self.run_setup()
+ File "/usr/lib/python3.10/site-packages/setuptools/build_meta.py", line 174, in run_setup
+ exec(compile(code, __file__, 'exec'), locals())
+ File "setup.py", line 32, in <module>
+ "version": versioneer.get_version(),
+AttributeError: module 'versioneer' has no attribute 'get_version'
+```
+---
+ setup.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/setup.py b/setup.py
+index e8dddc985..05765009c 100755
+--- a/setup.py
++++ b/setup.py
+@@ -23,7 +23,7 @@
+ # This is needed for versioneer to be importable when building with PEP 517.
+ # See <https://github.com/warner/python-versioneer/issues/193> and links
+ # therein for more information.
+-sys.path.append(os.path.dirname(__file__))
++sys.path.insert(0, os.path.dirname(__file__))
+
+ try:
+ import versioneer