commit: a34cfff94ac73ef6930d2de36cb4e89b4309b234 Author: Horea Christian <chr <AT> chymera <DOT> eu> AuthorDate: Mon Jul 18 16:46:05 2022 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Mon Jul 18 20:48:58 2022 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a34cfff9
dev-python/rsa: don't install LICENSE etc in site-packages Closes: https://bugs.gentoo.org/859175 Package-Manager: Portage-3.0.30, Repoman-3.0.3 Signed-off-by: Horea Christian <chr <AT> chymera.eu> Closes: https://github.com/gentoo/gentoo/pull/26466 Signed-off-by: Sam James <sam <AT> gentoo.org> dev-python/rsa/files/rsa-4.8-includes.patch | 28 ++++++++++++++++++++++ .../rsa/{rsa-4.8-r1.ebuild => rsa-4.8-r2.ebuild} | 2 ++ 2 files changed, 30 insertions(+) diff --git a/dev-python/rsa/files/rsa-4.8-includes.patch b/dev-python/rsa/files/rsa-4.8-includes.patch new file mode 100644 index 000000000000..181fd638d0de --- /dev/null +++ b/dev-python/rsa/files/rsa-4.8-includes.patch @@ -0,0 +1,28 @@ +https://github.com/sybrenstuvel/python-rsa/commit/3031bf5c6ae64083431e849903b0104d2cfae893 +https://bugs.gentoo.org/859175 + +From 3031bf5c6ae64083431e849903b0104d2cfae893 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgo...@gentoo.org> +Date: Thu, 27 Jan 2022 10:26:23 +0100 +Subject: [PATCH] Do not include arbitrary files in wheel + +Fix the include key to apply to sdist format only. Otherwise, the +listed files are added to the top directory of wheel as well and end up +being installed in top-level site-packages directory, e.g.: + + * FILES:+usr/lib/python3.9/site-packages/CHANGELOG.md + * FILES:+usr/lib/python3.9/site-packages/LICENSE + * FILES:+usr/lib/python3.9/site-packages/README.md +--- a/pyproject.toml ++++ b/pyproject.toml +@@ -26,7 +26,9 @@ classifiers = [ + "Topic :: Security :: Cryptography", + ] + include = [ +- "LICENSE", "README.md", "CHANGELOG.md", ++ { path = "LICENSE", format = "sdist" }, ++ { path = "README.md", format = "sdist" }, ++ { path = "CHANGELOG.md", format = "sdist" }, + ] + + [tool.poetry.dependencies] diff --git a/dev-python/rsa/rsa-4.8-r1.ebuild b/dev-python/rsa/rsa-4.8-r2.ebuild similarity index 94% rename from dev-python/rsa/rsa-4.8-r1.ebuild rename to dev-python/rsa/rsa-4.8-r2.ebuild index fffb3c5c50ad..5a4cdf383088 100644 --- a/dev-python/rsa/rsa-4.8-r1.ebuild +++ b/dev-python/rsa/rsa-4.8-r2.ebuild @@ -29,6 +29,8 @@ RDEPEND=" >=dev-python/pyasn1-0.1.3[${PYTHON_USEDEP}] " +PATCHES=( "${FILESDIR}/${P}-includes.patch" ) + distutils_enable_tests unittest src_prepare() {