mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-07-30 10:38:07 -07:00
dev-python/six: Remove any existing egg-info directory
Bug: https://bugs.gentoo.org/573114 Package-Manager: portage-2.2.27_p49
This commit is contained in:
@@ -48,3 +48,16 @@ python_install_all() {
|
||||
use doc && local HTML_DOCS=( documentation/_build/html/ )
|
||||
distutils-r1_python_install_all
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
# Remove this in the next version bump
|
||||
_cleanup() {
|
||||
local pyver=$("${PYTHON}" -c "from distutils.sysconfig import get_python_version; print(get_python_version())")
|
||||
local egginfo="${ROOT%/}$(python_get_sitedir)/${P}-py${pyver}.egg-info"
|
||||
if [[ -d ${egginfo} ]]; then
|
||||
echo rm -r "${egginfo}"
|
||||
rm -r "${egginfo}" || die "Failed to remove egg-info directory"
|
||||
fi
|
||||
}
|
||||
python_foreach_impl _cleanup
|
||||
}
|
||||
|
||||
@@ -39,3 +39,16 @@ python_install_all() {
|
||||
use doc && local HTML_DOCS=( documentation/_build/html/ )
|
||||
distutils-r1_python_install_all
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
# Remove this in the next version bump
|
||||
_cleanup() {
|
||||
local pyver=$("${PYTHON}" -c "from distutils.sysconfig import get_python_version; print(get_python_version())")
|
||||
local egginfo="${ROOT%/}$(python_get_sitedir)/${P}-py${pyver}.egg-info"
|
||||
if [[ -d ${egginfo} ]]; then
|
||||
echo rm -r "${egginfo}"
|
||||
rm -r "${egginfo}" || die "Failed to remove egg-info directory"
|
||||
fi
|
||||
}
|
||||
python_foreach_impl _cleanup
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user