aboutsummaryrefslogtreecommitdiff
path: root/sbopkglint
diff options
context:
space:
mode:
Diffstat (limited to 'sbopkglint')
-rwxr-xr-xsbopkglint40
1 files changed, 34 insertions, 6 deletions
diff --git a/sbopkglint b/sbopkglint
index 91a2e21..359312b 100755
--- a/sbopkglint
+++ b/sbopkglint
@@ -667,15 +667,43 @@ for package in $packages; do
olddir="$( pwd )"
package_fullpath="$( realpath $package )"
cd "$PKG"
- /sbin/explodepkg "$package_fullpath" &> $PKG/.tmp.$$
- # 20230319 bkw: explodepkg *never* exits with non-zero status, not
- # even if the package file doesn't exist. don't bother checking.
- # check for install/ dir instead: every valid slackware package has
- # to have this dir.
+ # 20260429 bkw: new helper explodepkg.sbopkglint. If not found in
+ # PATH, look in the same dir sbopkglint lives in. I had to make a
+ # modified explodepkg because the real one *never* shows any error
+ # message from tar or exits with non-zero status, even if the disk
+ # fills up, or if the *package file doesn't exist*.
+ # We had problems with large packages (e.g. cuda_toolkit_12 and _13)
+ # filling up $TMP, which resulted in lot of spurious errors caused
+ # by 0-byte files (because even when the storage is full, the inodes
+ # aren't exhausted, so *creating* files still works).
+ # Replacing explodepkg isn't ideal, but it's the least worst solution IMO.
+ exploder="$( type -p explodepkg.sbopkglint )"
+ if [ -z "$exploder" ]; then
+ exploder="$script_dir/explodepkg.sbopkglint"
+ if [ ! -x "$exploder" ]; then
+ die "Can't find explodepkg.sbopkglint in either PATH or $script_dir"
+ fi
+ fi
+
+ "$exploder" "$package_fullpath" &> $PKG/.tmp.$$
+ S="$?"
+
+ if [ "$S" != "0" ]; then
+ echo_FAILED
+ cat $PKG/.tmp.$$
+ echo "explodepkg.sbopkglint exited with status $S"
+ [ "$KEEP" = "" ] && rm -rf $PKG
+ exit_status=1
+ continue
+ fi
+
+ # 20260429 bkw: every valid Slackware package must have this dir. If it's
+ # missing, the user probably screwed up and gave the source tarball instead
+ # of the package file on the command line.
if [ ! -d install ]; then
cat $PKG/.tmp.$$
- warn "not a valid Slackware package"
+ warn "not a valid Slackware package (no install/ dir)"
echo_FAILED
rm -rf $PKG
exit_status=1