wayland-egl: Update wayland-egl-symbols-check for darwin

darwin prefixes C symbols with an underscore character

Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
This commit is contained in:
Jeremy Huddleston Sequoia 2023-01-27 19:54:02 -08:00
parent 75160d3ed3
commit ab94db3f6a

View file

@ -14,7 +14,15 @@ if ! test -n "$NM"; then
exit 99 exit 99
fi fi
# darwin prefixes C symbols with _ and uses a different nm invocation
case "$(uname -s)" in
Darwin)
AVAIL_FUNCS="$($NM -g --defined-only $LIB | awk '{print $3}' | sed 's:^_::')"
;;
*)
AVAIL_FUNCS="$($NM -D --format=bsd --defined-only $LIB | awk '{print $3}')" AVAIL_FUNCS="$($NM -D --format=bsd --defined-only $LIB | awk '{print $3}')"
;;
esac
# Official ABI, taken from the header. # Official ABI, taken from the header.
REQ_FUNCS="wl_egl_window_resize REQ_FUNCS="wl_egl_window_resize