Fix squisher on ArchLinux 32-bit chroot.
Something isn't setting the path correctly when running in a 32-bit
chroot environment in ArchLinux. This causes the script to cd into
$WORK/xbin. The PATH incorrectly contains ".", so all attempted
commands (rm, mv, cp) fail to execute as it is trying to execute
$WORK/xbin/{rm, mv, cp}.
diff --git a/tools/squisher b/tools/squisher
index 18c5155..cee085a 100755
--- a/tools/squisher
+++ b/tools/squisher
@@ -33,12 +33,11 @@
then
# Create the xbin squashfs
cp -a $XBIN $WORK/xbin/
- cd $WORK/xbin
- chown -R 1000:1000 *
- chmod -R 755 *
- rm su
- ln -s ../bin/su su
- mksquashfs . $WORK/xbin.sqf
+ chown -R 1000:1000 $WORK/xbin/*
+ chmod -R 755 $WORK/xbin/*
+ rm $WORK/xbin/su
+ ln -s $WORK/bin/su $WORK/xbin/su
+ mksquashfs $WORK/xbin/* $WORK/xbin.sqf
fi
# Unpack the otapackage and opticharge all apks