distutils-r1.eclass: use eapi9-pipestatus rather than assert

Preliminary work for EAPI 9, which bans the latter.

Signed-off-by: Eli Schwartz <eschwartz@gentoo.org>
This commit is contained in:
Eli Schwartz
2026-01-26 14:32:57 -05:00
parent a581c9de38
commit 55a92e44a2

View File

@@ -217,7 +217,7 @@ if [[ -z ${_DISTUTILS_R1_ECLASS} ]]; then
_DISTUTILS_R1_ECLASS=1
case ${EAPI} in
8) ;;
8) inherit eapi9-pipestatus ;;
*) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
esac
@@ -1454,13 +1454,13 @@ distutils-r1_python_install() {
(
cd "${reg_scriptdir}" && find . -mindepth 1
) | sort > "${T}"/.distutils-files-bin
assert "listing ${reg_scriptdir} failed"
pipestatus || die "listing ${reg_scriptdir} failed"
(
if [[ -d ${wrapped_scriptdir} ]]; then
cd "${wrapped_scriptdir}" && find . -mindepth 1
fi
) | sort > "${T}"/.distutils-files-wrapped
assert "listing ${wrapped_scriptdir} failed"
pipestatus || die "listing ${wrapped_scriptdir} failed"
if ! diff -U 0 "${T}"/.distutils-files-{bin,wrapped}; then
die "File lists for ${reg_scriptdir} and ${wrapped_scriptdir} differ (see diff above)"
fi