summaryrefslogtreecommitdiffstats
path: root/src/glx
diff options
context:
space:
mode:
Diffstat (limited to 'src/glx')
-rwxr-xr-xsrc/glx/tests/dispatch-index-check5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/glx/tests/dispatch-index-check b/src/glx/tests/dispatch-index-check
index 244634131f6..d1d0731347b 100755
--- a/src/glx/tests/dispatch-index-check
+++ b/src/glx/tests/dispatch-index-check
@@ -1,6 +1,11 @@
#!/usr/bin/env bash
set -e
+if [ -z "$srcdir" ]
+then
+ srcdir=$(dirname "$0")
+fi
+
# extract enum definition
dispatch_list=$(sed '/__GLXdispatchIndex/,/__GLXdispatchIndex/!d' \
"$srcdir"/../g_glxglvnddispatchindices.h)