system-image-from-ota: various fixes
requested to merge amartinz/halium-generic-adaptation-build-tools:halium-10-focal-system-image-from-ota-fixes into halium-10-focal
system-image-from-ota: fix mktemp call
The t
option is deprecated and causes failure:
mktemp: failed to create directory via template ‘/tmp/tmp.Q8qr0T0KAm/tmp.XXXXXXXXXX’: No such file or directory
system-image-from-ota: losetup requires root
$> ./build/system-image-from-ota.sh ota/ubuntu_command ota_out
System image: Starting image Upgrade pre
System image: Starting image upgrader: Do 24 Nov 2022 18:45:30 CET
System image: Processing the command file
System image: Formating: system
0+0 records in
0+0 records out
0 bytes copied, 6,9211e-05 s, 0,0 kB/s
mke2fs 1.46.5 (30-Dec-2021)
Discarding device blocks: done
Creating filesystem with 768000 4k blocks and 192000 inodes
Filesystem UUID: a82e2927-67bf-4918-a5f3-3f16efef8215
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912
Allocating group tables: done
Writing inode tables: done
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done
System image: Loading keyring: image-master.tar.xz
System image: Loading keyring: image-signing.tar.xz
losetup: cannot find an unused loop device: Permission denied