aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sbopkglint.d/65-python.t.sh16
1 files changed, 16 insertions, 0 deletions
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.$$