@@ -20,5 +20,6 @@ libdrm_omapinclude_HEADERS = omap_drmif.h
pkgconfigdir = @pkgconfigdir@
pkgconfig_DATA = libdrm_omap.pc
+AM_TESTS_ENVIRONMENT = top_srcdir='$(top_srcdir)'
TESTS = omap-symbol-check
EXTRA_DIST = $(TESTS)
@@ -1,15 +1,10 @@
#!/bin/bash
+set -eu
-# The following symbols (past the first five) are taken from the public headers.
-# A list of the latter should be available Makefile.am/libdrm_omap*HEADERS
+LIB=.libs/libdrm_omap.so
-FUNCS=$($NM -D --format=bsd --defined-only ${1-.libs/libdrm_omap.so} | awk '{print $3}'| while read func; do
-( grep -q "^$func$" || echo $func ) <<EOF
-__bss_start
-_edata
-_end
-_fini
-_init
+# Official ABI, taken from the header.
+REQ_FUNCS="
omap_bo_cpu_fini
omap_bo_cpu_prep
omap_bo_del
@@ -28,8 +23,6 @@ omap_device_new
omap_device_ref
omap_get_param
omap_set_param
-EOF
-done)
+"
-test ! -n "$FUNCS" || echo $FUNCS
-test ! -n "$FUNCS"
+source "$top_srcdir"/symbols-check
Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com> --- omap/Makefile.am | 1 + omap/omap-symbol-check | 19 ++++++------------- 2 files changed, 7 insertions(+), 13 deletions(-)