mirror of
https://gitlab.freedesktop.org/emersion/libdisplay-info.git
synced 2024-12-27 21:59:22 +01:00
79e0ac2dd4
This will allow us to check that we find the same failures as upstream edid-decode. Signed-off-by: Simon Ser <contact@emersion.fr>
17 lines
343 B
Bash
Executable file
17 lines
343 B
Bash
Executable file
#!/bin/sh -eu
|
|
|
|
workdir="$(mktemp -d)"
|
|
cleanup() {
|
|
rm -rf "$workdir"
|
|
}
|
|
trap cleanup EXIT
|
|
|
|
edid="$1"
|
|
"$REF_EDID_DECODE" --skip-hex-dump --check --skip-sha <"$edid" >"$workdir/ref" || [ $? = 254 ]
|
|
"$DI_EDID_DECODE" <"$edid" >"$workdir/di"
|
|
|
|
if [ -f "$edid.diff" ]; then
|
|
patch "$workdir/ref" "$edid.diff"
|
|
fi
|
|
|
|
diff -u "$workdir/ref" "$workdir/di"
|