summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'eclass/distutils-r1.eclass')
-rw-r--r--eclass/distutils-r1.eclass17
1 files changed, 17 insertions, 0 deletions
diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
index dd7f90340141..49c98290f30f 100644
--- a/eclass/distutils-r1.eclass
+++ b/eclass/distutils-r1.eclass
@@ -104,6 +104,8 @@ esac
#
# - jupyter - jupyter_packaging backend
#
+# - maturin - maturin backend
+#
# - pdm - pdm.pep517 backend
#
# - poetry - poetry-core backend
@@ -212,6 +214,10 @@ _distutils_set_globals() {
bdep+='
>=dev-python/jupyter_packaging-0.11.1[${PYTHON_USEDEP}]'
;;
+ maturin)
+ bdep+='
+ >=dev-util/maturin-0.12.7[${PYTHON_USEDEP}]'
+ ;;
pdm)
bdep+='
>=dev-python/pdm-pep517-0.12.3[${PYTHON_USEDEP}]'
@@ -992,6 +998,9 @@ _distutils-r1_backend_to_key() {
jupyter_packaging.build_api)
echo jupyter
;;
+ maturin)
+ echo maturin
+ ;;
pdm.pep517.api)
echo pdm
;;
@@ -1210,6 +1219,14 @@ distutils-r1_python_compile() {
esetup.py build -j "${jobs}" "${@}"
fi
;;
+ maturin)
+ # auditwheel may attempt to auto-bundle libraries, bug #831171
+ local -x MATURIN_PEP517_ARGS=--skip-auditwheel
+
+ # support cargo.eclass' IUSE=debug if available
+ in_iuse debug && use debug &&
+ MATURIN_PEP517_ARGS+=" --cargo-extra-args=--profile=dev"
+ ;;
esac
if [[ ${DISTUTILS_USE_PEP517} ]]; then