summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2017-05-05 23:20:12 +0200
committerMichał Górny <mgorny@gentoo.org>2017-05-16 19:11:29 +0200
commit5e7c36d286609ee9487e58f5cedb1cb6388e3c73 (patch)
tree4a8fcdfaf7c45d270216859610f4e20ac79ed387 /eclass/distutils-r1.eclass
parentdistutils-r1.eclass: Warn if *-nspkg.pth files are installed (diff)
downloadgentoo-5e7c36d286609ee9487e58f5cedb1cb6388e3c73.tar.gz
gentoo-5e7c36d286609ee9487e58f5cedb1cb6388e3c73.tar.bz2
gentoo-5e7c36d286609ee9487e58f5cedb1cb6388e3c73.zip
distutils-r1.eclass: Namespace & doc _clean_egg_info
Prefix the _clean_egg_info function with an appropriate namespace, and document its purpose with eclassdoc format. Be more verbose on the exact problem being solved; remove URL to old upstream bug tracker that no longer exists.
Diffstat (limited to 'eclass/distutils-r1.eclass')
-rw-r--r--eclass/distutils-r1.eclass14
1 files changed, 9 insertions, 5 deletions
diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
index 5df7234332d3..1376326c9579 100644
--- a/eclass/distutils-r1.eclass
+++ b/eclass/distutils-r1.eclass
@@ -770,10 +770,14 @@ distutils-r1_src_compile() {
fi
}
-_clean_egg_info() {
- # Work around for setuptools test behavior (bug 534058).
- # https://bitbucket.org/pypa/setuptools/issue/292
- rm -rf "${BUILD_DIR}"/lib/*.egg-info
+# @FUNCTION: _distutils-r1_clean_egg_info
+# @INTERNAL
+# @DESCRIPTION:
+# Clean up potential stray egg-info files left by setuptools test phase.
+# Those files ended up being unversioned, and caused issues:
+# https://bugs.gentoo.org/534058
+_distutils-r1_clean_egg_info() {
+ rm -rf "${BUILD_DIR}"/lib/*.egg-info || die
}
distutils-r1_src_test() {
@@ -781,7 +785,7 @@ distutils-r1_src_test() {
if declare -f python_test >/dev/null; then
_distutils-r1_run_foreach_impl python_test
- _distutils-r1_run_foreach_impl _clean_egg_info
+ _distutils-r1_run_foreach_impl _distutils-r1_clean_egg_info
fi
if declare -f python_test_all >/dev/null; then