From 8de8e6433515a071b780d927b50035ca46fbd030 Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Sun, 14 May 2023 17:35:57 -0400 Subject: sbopkglint: add check for broken python modules. --- sbopkglint.d/65-python.t.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 sbopkglint.d/65-python.t.sh diff --git a/sbopkglint.d/65-python.t.sh b/sbopkglint.d/65-python.t.sh new file mode 100644 index 0000000..5c81d43 --- /dev/null +++ b/sbopkglint.d/65-python.t.sh @@ -0,0 +1,16 @@ +#!/bin/sh + +# sbopkglint test, must be sourced by sbopkglint (not run standalone). + +# PKG, PRGNAM, VERSION, ARCH are set by sbopkglint. also the current +# directory is the root of the installed package tree. + +####################################################################### +# check for badly-built python packages that end up named UNKNOWN. +# at some point there will probably be more python checks added here. + +find usr/lib*/python* -type d -a -name 'UNKNOWN*' 2>/dev/null > .badpython.$$ +if [ -s .badpython.$$ ]; then + warn "invalid/broken Python module(s): $(cat .badpython.$$)" +fi +rm -f .badpython.$$ -- cgit v1.2.3