. "$BST_LIB" require hexdump util-linux/present # hexdump renders the canonical dump (offset column, hex bytes, ASCII gutter): # "ABC" -> "00000000 41 42 43 |ABC|". The argv form `hexdump ` uses # freopen(), which needs dup3(2) — unwired on this runtime, so it fails ENOSYS # (brintos.io kernel gap); reading the same file on stdin exercises the identical # formatting path and works. tmp=${TMPDIR:-/tmp}/bst-ul.$$ printf 'ABC' > "$tmp" check_out util-linux/hexdump-canonical "41 42 43" hexdump -C < "$tmp" rm -f "$tmp" # dmesg reads the kernel ring buffer via syslog(2). Seed a unique marker through # /dev/kmsg and read it back, rather than looking for the boot banner: the ring # buffer holds ~140 kB of rendered text and this kernel traces every fork and # every exec into it, so the banner scrolls out within seconds of test activity # and is long gone on an image with real uptime. A round trip is wrap-immune and # still red for a dmesg that prints nothing. kmsg=bst-dmesg-$$ if printf '%s\n' "$kmsg" > /dev/kmsg 2>/dev/null; then check_out util-linux/dmesg "$kmsg" dmesg else bst_notok util-linux/dmesg "/dev/kmsg not writable, so dmesg's read of the ring buffer cannot be asserted" fi # lsblk enumerates block devices from sysfs. The browser runtime (virtio-fs root) # exposes no block layer, so lsblk lists nothing but runs clean. check util-linux/lsblk-runs lsblk