gbm: use new symbols check script
authorEric Engestrom <eric.engestrom@intel.com>
Thu, 11 Oct 2018 13:43:35 +0000 (14:43 +0100)
committerEric Engestrom <eric@engestrom.ch>
Wed, 10 Jul 2019 11:27:51 +0000 (11:27 +0000)
Note: the list in gbm-symbols.txt is the same as the one that was in
gbm-symbols-check, I just took the opportunity to sort it.

Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by Dylan Baker <dylan@pnwbakers.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
src/gbm/gbm-symbols-check [deleted file]
src/gbm/gbm-symbols.txt [new file with mode: 0755]
src/gbm/meson.build

diff --git a/src/gbm/gbm-symbols-check b/src/gbm/gbm-symbols-check
deleted file mode 100755 (executable)
index e28c52d..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-#!/bin/sh
-set -eu
-
-LIB=${1-.libs/libgbm.so}
-
-if ! [ -f "$LIB" ]
-then
-  exit 1
-fi
-
-FUNCS=$($NM -D --defined-only $LIB | grep -o "T .*" | cut -c 3- | while read func; do
-( grep -q "^$func$" || echo $func )  <<EOF
-gbm_device_get_fd
-gbm_device_get_backend_name
-gbm_device_is_format_supported
-gbm_device_destroy
-gbm_device_get_format_modifier_plane_count
-gbm_create_device
-gbm_bo_create
-gbm_bo_create_with_modifiers
-gbm_bo_import
-gbm_bo_map
-gbm_bo_unmap
-gbm_bo_get_width
-gbm_bo_get_height
-gbm_bo_get_stride
-gbm_bo_get_stride_for_plane
-gbm_bo_get_format
-gbm_bo_get_bpp
-gbm_bo_get_offset
-gbm_bo_get_device
-gbm_bo_get_handle
-gbm_bo_get_fd
-gbm_bo_get_plane_count
-gbm_bo_get_handle_for_plane
-gbm_bo_get_modifier
-gbm_bo_write
-gbm_bo_set_user_data
-gbm_bo_get_user_data
-gbm_bo_destroy
-gbm_format_get_name
-gbm_surface_create
-gbm_surface_create_with_modifiers
-gbm_surface_lock_front_buffer
-gbm_surface_release_buffer
-gbm_surface_has_free_buffers
-gbm_surface_destroy
-_fini
-_init
-EOF
-done)
-
-test ! -n "$FUNCS" || echo $FUNCS
-test ! -n "$FUNCS"
diff --git a/src/gbm/gbm-symbols.txt b/src/gbm/gbm-symbols.txt
new file mode 100755 (executable)
index 0000000..84ab188
--- /dev/null
@@ -0,0 +1,35 @@
+gbm_device_get_fd
+gbm_device_get_backend_name
+gbm_device_is_format_supported
+gbm_device_destroy
+gbm_device_get_format_modifier_plane_count
+gbm_create_device
+gbm_bo_create
+gbm_bo_create_with_modifiers
+gbm_bo_import
+gbm_bo_map
+gbm_bo_unmap
+gbm_bo_get_width
+gbm_bo_get_height
+gbm_bo_get_stride
+gbm_bo_get_stride_for_plane
+gbm_bo_get_format
+gbm_bo_get_bpp
+gbm_bo_get_offset
+gbm_bo_get_device
+gbm_bo_get_handle
+gbm_bo_get_fd
+gbm_bo_get_plane_count
+gbm_bo_get_handle_for_plane
+gbm_bo_get_modifier
+gbm_bo_write
+gbm_bo_set_user_data
+gbm_bo_get_user_data
+gbm_bo_destroy
+gbm_format_get_name
+gbm_surface_create
+gbm_surface_create_with_modifiers
+gbm_surface_lock_front_buffer
+gbm_surface_release_buffer
+gbm_surface_has_free_buffers
+gbm_surface_destroy
index b7262c5980240638d89bedbee037e65bb1b95f68..39fa0386a657ae52c6edbd1fc697dc3dcfcf9c4f 100644 (file)
@@ -69,9 +69,12 @@ pkg.generate(
 if with_tests and prog_nm.found()
   test(
     'gbm-symbols-check',
-    find_program('gbm-symbols-check'),
-    env : env_test,
-    args : libgbm,
+    symbols_check,
+    args : [
+      '--lib', libgbm,
+      '--symbols-file', files('gbm-symbols.txt'),
+      '--nm', prog_nm.path(),
+    ],
     suite : ['gbm'],
   )
 endif