Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 780807 - distutils-r1.eclass: DISTUTILS_OPTIONAL=1 doesn't work as expected when DISTUTILS_SINGLE_IMPL=1 is also set.
Summary: distutils-r1.eclass: DISTUTILS_OPTIONAL=1 doesn't work as expected when DISTU...
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-07 11:02 UTC by Alfred Wingate
Modified: 2021-04-14 20:36 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alfred Wingate 2021-04-07 11:02:53 UTC
Setting DISTUTILS_SINGLE_IMPL=1 together with DISTUTILS_OPTIONAL=1 doesn't work as expected due to python-single-r1 eclass exporting pkg_setup  unconditionally and therefore contradicts with what is said in eclass documentation.

> "... and no phase functions will be exported."

Essentially means that you can't have optional single python implementation distutils-r1 use in an ebuild.

Reproducible: Always

Steps to Reproduce:
1. Create an distutils-r1 ebuild DISTUTILS_OPTIONAL=1 and DISTUTILS_SINGLE_IMPL=1
2. Try to merge with empty or unset PYTHON_SINGLE_TARGET
Actual Results:  
Experience failure in pkg_setup due to unset PYTHON_SINGLE_TARGET

Expected Results:  
It should succeed without an error.

# A very basic ebuild that experiences the issue

EAPI=7

DISTUTILS_SINGLE_IMPL=1
DISTUTILS_OPTIONAL=1
PYTHON_COMPAT=(python3_{7..9})

inherit distutils-r1
SLOT="0"