[PATCH libdrm 16/24] nouveau: add symbols test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Emil Velikov <emil.l.velikov@xxxxxxxxx>
---
 nouveau/Makefile.am          |  3 ++-
 nouveau/nouveau-symbol-check | 52 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 54 insertions(+), 1 deletion(-)
 create mode 100755 nouveau/nouveau-symbol-check

diff --git a/nouveau/Makefile.am b/nouveau/Makefile.am
index 1ca235d..2f61351 100644
--- a/nouveau/Makefile.am
+++ b/nouveau/Makefile.am
@@ -21,4 +21,5 @@ libdrm_nouveauinclude_HEADERS = $(LIBDRM_NOUVEAU_H_FILES)
 pkgconfigdir = @pkgconfigdir@
 pkgconfig_DATA = libdrm_nouveau.pc
 
-EXTRA_DIST = Android.mk
+TESTS = nouveau-symbol-check
+EXTRA_DIST = Android.mk $(TESTS)
diff --git a/nouveau/nouveau-symbol-check b/nouveau/nouveau-symbol-check
new file mode 100755
index 0000000..0fef563
--- /dev/null
+++ b/nouveau/nouveau-symbol-check
@@ -0,0 +1,52 @@
+#!/bin/bash
+
+# The following symbols (past the first five) are taken from the public headers.
+# A list of the latter should be available Makefile.sources/LIBDRM_NOUVEAU_H_FILES
+
+FUNCS=$(nm -D --format=bsd --defined-only ${1-.libs/libdrm_nouveau.so} | awk '{print $3}'| while read func; do
+( grep -q "^$func$" || echo $func )  <<EOF
+__bss_start
+_edata
+_end
+_fini
+_init
+nouveau_bo_map
+nouveau_bo_name_get
+nouveau_bo_name_ref
+nouveau_bo_new
+nouveau_bo_prime_handle_ref
+nouveau_bo_ref
+nouveau_bo_set_prime
+nouveau_bo_wait
+nouveau_bo_wrap
+nouveau_bufctx_del
+nouveau_bufctx_mthd
+nouveau_bufctx_new
+nouveau_bufctx_refn
+nouveau_bufctx_reset
+nouveau_client_del
+nouveau_client_new
+nouveau_device_del
+nouveau_device_open
+nouveau_device_open_existing
+nouveau_device_wrap
+nouveau_getparam
+nouveau_object_del
+nouveau_object_find
+nouveau_object_new
+nouveau_pushbuf_bufctx
+nouveau_pushbuf_data
+nouveau_pushbuf_del
+nouveau_pushbuf_kick
+nouveau_pushbuf_new
+nouveau_pushbuf_refd
+nouveau_pushbuf_refn
+nouveau_pushbuf_reloc
+nouveau_pushbuf_space
+nouveau_pushbuf_validate
+nouveau_setparam
+EOF
+done)
+
+test ! -n "$FUNCS" || echo $FUNCS
+test ! -n "$FUNCS"
-- 
2.3.1

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel





[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux