working on adding KHR functions that were promoted to Vulkan 1.1
[kazan.git] / run-cts.sh
1 #!/bin/bash
2
3 set -e
4
5 do_update=1
6 if [[ "$*" == '--no-update' ]]; then
7 do_update=0
8 elif [[ "$*" != '' ]]; then
9 printf "unknown arguments\nusage: %s [--no-update]\n" "$0" >&2
10 exit 1
11 fi
12
13 cts_source="$(realpath VK-GL-CTS)"
14
15 if [[ ! -d "$cts_source" ]]; then
16 if ((do_update)); then
17 git clone "https://github.com/KhronosGroup/VK-GL-CTS"
18 else
19 echo "need to run without --no-update" >&2
20 exit 1
21 fi
22 fi
23 cts_build="$(realpath VK-GL-CTS/build)"
24 if ((do_update)); then
25 (
26 cd "$cts_source"
27 git pull
28 python2 external/fetch_sources.py
29 )
30 fi
31 if [[ ! -d "$cts_build" ]]; then
32 if ((do_update)); then
33 (
34 mkdir "$cts_build"
35 cd "$cts_build"
36 cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug ..
37 )
38 else
39 echo "need to run without --no-update" >&2
40 exit 1
41 fi
42 fi
43 (
44 cd "$cts_build"
45 ninja
46 )
47 exec ./run.sh bash -c "cd '$cts_build'/external/vulkancts/modules/vulkan; exec ./deqp-vk --deqp-caselist-file='$cts_source'/external/vulkancts/mustpass/1.1.3/vk-default.txt --deqp-log-images=disable --deqp-log-shader-sources=disable"