pnd_make.sh: use root uid/gid for squashfs, not user's
authorGrazvydas Ignotas <notasas@gmail.com>
Tue, 11 Jun 2013 22:42:46 +0000 (01:42 +0300)
committerGrazvydas Ignotas <notasas@gmail.com>
Tue, 11 Jun 2013 22:50:29 +0000 (01:50 +0300)
there is no point using uid/gid of current user that's creating the
.pnd (which can be almost any uid/gid as it's on the host system),
the SD card/appdata is owned by root by default, so archived
files should be too.

It's also the reason why it wasn't possible to update existing files
(appdata and pnd uid/git did not match), but also right permissions
must be set.

testdata/scripts/pnd_make.sh

index 96c3270..fed3396 100755 (executable)
@@ -283,9 +283,9 @@ then
        fi
        if [ $SQUASHXZ ];
        then
-               mksquashfs $FOLDER $PNDNAME.iso -comp xz -Xbcj arm,armthumb
+               mksquashfs $FOLDER $PNDNAME.iso -all-root -force-gid 0 -comp xz -Xbcj arm,armthumb
        else
-               mksquashfs $FOLDER $PNDNAME.iso
+               mksquashfs $FOLDER $PNDNAME.iso -all-root -force-gid 0
        fi
 else
        check_for_tool mkisofs