From e6b96dceabb9cc4e79653c7992b8c16ac3d234ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20=C5=BBygowski?= Date: Wed, 5 Oct 2022 13:41:03 +0200 Subject: [PATCH] util/chromeos/gen_test_hwid.sh: Replace usage of hexdump MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Hexdump command is not available in coreboot-sdk. Replace it with equivalent implementation using commands that are present in the container. TEST=Passed "VP46XX" as prefix variable and it produced the same crc32 result before and after the change. Signed-off-by: Michał Żygowski Change-Id: Icad93933335b8c5ebd8fee74cc9aaed36bb56482 Reviewed-on: https://review.coreboot.org/c/coreboot/+/68133 Tested-by: build bot (Jenkins) Reviewed-by: Julius Werner --- util/chromeos/gen_test_hwid.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/chromeos/gen_test_hwid.sh b/util/chromeos/gen_test_hwid.sh index 9dfbce5a85..8f3b948a96 100755 --- a/util/chromeos/gen_test_hwid.sh +++ b/util/chromeos/gen_test_hwid.sh @@ -13,7 +13,7 @@ main() { local prefix="$(echo "${board}" | tr a-z A-Z) TEST" # gzip has second-to-last 4 bytes in CRC32. local crc32="$(printf "${prefix}" | gzip -1 | tail -c 8 | head -c 4 | \ - hexdump -e '1/4 "%04u" ""' | tail -c 4)" + od -An -vtu4 | tr -d '\n' | tail -c 4)" echo "${prefix}" "${crc32}" }