[Mesa-dev] [PATCH 3/4] glsl/glcpp/tests: reinstate srcdir/abs_builddir blurb
Dylan Baker
dylan at pnwbakers.com
Tue Apr 24 18:21:10 UTC 2018
Sure,
Reviewed-by: Dylan Baker <dylan at pnwbakers.com>
Quoting Emil Velikov (2018-04-24 10:49:21)
> From: Emil Velikov <emil.velikov at collabora.com>
>
> Bring back the "detection" of the said variables, to allow
> standalone execution.
>
> Fixes: db8cd8e36771 ("glcpp/tests: Convert shell scripts to a python
> script")
> Cc: Dylan Baker <dylan at pnwbakers.com>
> Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
> ---
> src/compiler/glsl/glcpp/tests/glcpp-test.sh | 13 +++++++++++++
> 1 file changed, 13 insertions(+)
>
> diff --git a/src/compiler/glsl/glcpp/tests/glcpp-test.sh b/src/compiler/glsl/glcpp/tests/glcpp-test.sh
> index 7ca8aa26a8..b8397ec890 100755
> --- a/src/compiler/glsl/glcpp/tests/glcpp-test.sh
> +++ b/src/compiler/glsl/glcpp/tests/glcpp-test.sh
> @@ -1,3 +1,16 @@
> #!/bin/sh
>
> +if [ -z "$srcdir" -o -z "$abs_builddir" ]; then
> + echo ""
> + echo "Warning: you're invoking the script manually and things may fail."
> + echo "Attempting to determine/set srcdir and abs_builddir variables."
> + echo ""
> +
> + # Should point to `dirname Makefile.glsl.am`
> + srcdir=./../../../
> + cd `dirname "$0"`
> + # Should point to `dirname Makefile` equivalent to the above.
> + abs_builddir=`pwd`/../../../
> +fi
> +
> $PYTHON2 $srcdir/glsl/glcpp/tests/glcpp_test.py $abs_builddir/glsl/glcpp/glcpp $srcdir/glsl/glcpp/tests --unix --windows --oldmac --bizarro
> --
> 2.16.0
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 228 bytes
Desc: signature
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180424/ea5849d0/attachment-0001.sig>
More information about the mesa-dev
mailing list