glsl/tests/optimization-test: correctly set compare_ir
authorEmil Velikov <emil.velikov@collabora.com>
Mon, 27 Feb 2017 18:21:36 +0000 (18:21 +0000)
committerEmil Velikov <emil.l.velikov@gmail.com>
Tue, 28 Mar 2017 14:31:23 +0000 (15:31 +0100)
Now that we have srcdir we can use it to correctly manage/point to the
script. Effectively fixing OOT invokation of `make check'.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
src/compiler/glsl/tests/optimization-test.sh

index a7d771170c5f1873f0af23289729c8032a750389..5ae5684f7c41d9e75a2b000d3ac887d9be1b555e 100755 (executable)
@@ -1,11 +1,5 @@
 #!/bin/sh
 
-if [ ! -z "$srcdir" ]; then
-   compare_ir=`pwd`/tests/compare_ir.py
-else
-   compare_ir=./compare_ir.py
-fi
-
 if [ -z "$PYTHON2" ]; then
     PYTHON2=python2
 fi
@@ -29,6 +23,8 @@ if [ -z "$srcdir" -o -z "$abs_builddir" ]; then
     abs_builddir=`pwd`/../../
 fi
 
+compare_ir=$srcdir/glsl/tests/compare_ir.py
+
 total=0
 pass=0