The PEP 517 build-time deps have gotten more complex, and largely depend
on the internal eclass logic used to build and install wheels.
Introduce a DISTUTILS_DEPS output variable that contains the correct
BDEPEND string for use in DISTUTILS_OPTIONAL=1 ebuilds.
Signed-off-by: Michał Górny <
[email protected]>
---
eclass/distutils-r1.eclass | 34 +++++++++++++++++++++++++++++++++-
1 file changed, 33 insertions(+), 1 deletion(-)
diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
index 4a9fdb4018b4..a0ad598eb58f 100644
--- a/eclass/distutils-r1.eclass
+++ b/eclass/distutils-r1.eclass
@@ -128,6 +128,24 @@ esac
# It is available only in non-PEP517 mode. It needs to be set before
# the inherit line.
+# @ECLASS-VARIABLE: DISTUTILS_DEPS
+# @OUTPUT_VARIABLE
+# @DESCRIPTION:
+# This is an eclass-generated build-time dependency string for the build
+# system packages. This string is automatically appended to BDEPEND
+# unless DISTUTILS_OPTIONAL is used. This variable is available only
+# in PEP 517 mode.
+#
+# Example use:
+# @CODE
+# DISTUTILS_OPTIONAL=1
+# # ...
+# RDEPEND="${PYTHON_DEPS}"
+# BDEPEND="
+# ${PYTHON_DEPS}
+# ${DISTUTILS_DEPS}"
+# @CODE
+
if [[ ! ${_DISTUTILS_R1} ]]; then
[[ ${EAPI} == 6 ]] && inherit eutils xdg-utils
@@ -156,7 +174,7 @@ _d