From 57c880270e0b7ebe3134ac82c489996f428261e0 Mon Sep 17 00:00:00 2001 From: classabbyamp Date: Wed, 4 Dec 2024 11:27:02 -0500 Subject: [PATCH] fixup! common/hooks/pre-pkg/04-generate-provides: generate provides for python modules --- common/hooks/pre-pkg/04-generate-provides.sh | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/common/hooks/pre-pkg/04-generate-provides.sh b/common/hooks/pre-pkg/04-generate-provides.sh index 80c2142d83333d..f095854d434268 100644 --- a/common/hooks/pre-pkg/04-generate-provides.sh +++ b/common/hooks/pre-pkg/04-generate-provides.sh @@ -3,16 +3,12 @@ # This hook executes the following tasks: # - Generates provides file with provides entries for xbps-create(1) -py3_cmd() { - env PYTHONPATH="${XBPS_MASTERDIR}/${py3_sitelib}-bootstrap" "${py3_bin}" "$@" -} - generate_python_provides() { local py3_bin="${XBPS_MASTERDIR}/usr/bin/python3" - if [ -z "$nopyprovides" ] && [ -d "${PKGDESTDIR}/${py3_sitelib}" ] && \ - [ -x "${py3_bin}" ] && py3_cmd -c "import packaging"; then - py3_cmd "${XBPS_COMMONDIR}"/scripts/parse-py-metadata.py \ + if [ -z "$nopyprovides" ] && [ -d "${PKGDESTDIR}/${py3_sitelib}" ] && [ -x "${py3_bin}" ]; then + PYTHONPATH="${XBPS_MASTERDIR}/${py3_sitelib}-bootstrap" "${py3_bin}" \ + "${XBPS_COMMONDIR}"/scripts/parse-py-metadata.py \ -S "${PKGDESTDIR}/${py3_sitelib}" -v "${pkgver}" provides fi }