summaryrefslogtreecommitdiff
path: root/metadata/install-qa-check.d/60python-site
diff options
context:
space:
mode:
Diffstat (limited to 'metadata/install-qa-check.d/60python-site')
-rw-r--r--metadata/install-qa-check.d/60python-site13
1 files changed, 10 insertions, 3 deletions
diff --git a/metadata/install-qa-check.d/60python-site b/metadata/install-qa-check.d/60python-site
index 3791fa80ecdd..49d4b3a1a830 100644
--- a/metadata/install-qa-check.d/60python-site
+++ b/metadata/install-qa-check.d/60python-site
@@ -75,6 +75,13 @@ python_site_check() {
local sitedir=( "${pydir}"/site-packages )
[[ -d ${sitedir} ]] || continue
+ local modname=$(
+ "${impl}" - <<-EOF
+ import sysconfig
+ print(sysconfig.get_config_var("SHLIB_SUFFIX"))
+ EOF
+ )
+
# check for bad package versions
while IFS= read -d $'\0' -r f; do
bad_versions+=( "${f#${ED}}" )
@@ -107,7 +114,7 @@ python_site_check() {
-name '*.pth' -o \
-name '*.py' -o \
-name '*.pyi' -o \
- -name "*$(get_modname)" -o \
+ -name "*${modname}" -o \
-name 'README.txt' \
')' -print0
)
@@ -130,8 +137,8 @@ python_site_check() {
wrong_ext+=( "${f#${ED}}" )
done < <(
find "${sitedir}" '(' \
- -name "*.pypy*$(get_modname)" -o \
- -name "*.cpython*$(get_modname)" \
+ -name "*.pypy*${modname}" -o \
+ -name "*.cpython*${modname}" \
')' -a '!' -name "*${ext_suffix}" -print0
)