xref: /aosp_15_r20/external/deqp/README.md (revision 35238bce31c2a825756842865a792f8cf7f89930)
1*35238bceSAndroid Build Coastguard WorkerVK-GL-CTS README
2*35238bceSAndroid Build Coastguard Worker===========
3*35238bceSAndroid Build Coastguard Worker
4*35238bceSAndroid Build Coastguard WorkerThis repository contains Khronos Conformance Testing Suite called VK-GL-CTS
5*35238bceSAndroid Build Coastguard Workerwhich originated from dEQP (drawElements Quality Program).
6*35238bceSAndroid Build Coastguard WorkerVK-GL-CTS contains tests for several graphics APIs, including
7*35238bceSAndroid Build Coastguard WorkerOpenGL, OpenGL ES, EGL, Vulkan, and Vulkan SC.
8*35238bceSAndroid Build Coastguard Worker
9*35238bceSAndroid Build Coastguard WorkerDocumentation
10*35238bceSAndroid Build Coastguard Worker-------------
11*35238bceSAndroid Build Coastguard Worker
12*35238bceSAndroid Build Coastguard WorkerUp-to-date documentation for VK-GL-CTS is available at:
13*35238bceSAndroid Build Coastguard Worker
14*35238bceSAndroid Build Coastguard Worker* [The VK-GL-CTS wiki for Khronos members](https://gitlab.khronos.org/Tracker/vk-gl-cts/wikis/home)
15*35238bceSAndroid Build Coastguard Worker* [The VK-GL-CTS wiki for non-Khronos members](https://github.com/KhronosGroup/VK-GL-CTS/wiki)
16*35238bceSAndroid Build Coastguard Worker
17*35238bceSAndroid Build Coastguard WorkerThe .qpa logs generated by the conformance tests may contain embedded PNG images of the results.
18*35238bceSAndroid Build Coastguard WorkerThese can be viewed with `scripts/qpa_image_viewer.html`, by opening the file
19*35238bceSAndroid Build Coastguard Workerwith a web browser and following its instructions, or using the
20*35238bceSAndroid Build Coastguard Worker[Cherry](https://android.googlesource.com/platform/external/cherry/)
21*35238bceSAndroid Build Coastguard Workertool.
22*35238bceSAndroid Build Coastguard Worker
23*35238bceSAndroid Build Coastguard WorkerKhronos Vulkan Conformance Tests
24*35238bceSAndroid Build Coastguard Worker--------------------------------
25*35238bceSAndroid Build Coastguard Worker
26*35238bceSAndroid Build Coastguard WorkerThis repository includes Khronos Vulkan CTS under `external/vulkancts` directory.
27*35238bceSAndroid Build Coastguard WorkerFor more information see [Vulkan CTS README](external/vulkancts/README.md).
28*35238bceSAndroid Build Coastguard Worker
29*35238bceSAndroid Build Coastguard WorkerKhronos OpenGL / OpenGL ES Conformance Tests
30*35238bceSAndroid Build Coastguard Worker--------------------------------
31*35238bceSAndroid Build Coastguard Worker
32*35238bceSAndroid Build Coastguard WorkerThis repository includes Khronos OpenGL / OpenGL ES CTS under `external/openglcts` directory.
33*35238bceSAndroid Build Coastguard WorkerFor more information see [OpenGL / OpenGL ES CTS README](external/openglcts/README.md).
34*35238bceSAndroid Build Coastguard Worker
35*35238bceSAndroid Build Coastguard WorkerSelecting a subset of targets to build by default
36*35238bceSAndroid Build Coastguard Worker--------------------------------
37*35238bceSAndroid Build Coastguard Worker
38*35238bceSAndroid Build Coastguard WorkerWhen configuring the source code of VK-GL-CTS for running either Vulkan
39*35238bceSAndroid Build Coastguard WorkerConformance Tests or OpenGL(ES) Conformance Tests as described above, CMake will
40*35238bceSAndroid Build Coastguard Workergenerate build files that, by default on desktop platforms, will build every
41*35238bceSAndroid Build Coastguard Workerpossible project binary. This may be undesirable due the amount of time and disk
42*35238bceSAndroid Build Coastguard Workerspace needed to perform the build.
43*35238bceSAndroid Build Coastguard Worker
44*35238bceSAndroid Build Coastguard WorkerOne way of selecting only a subset of the targets to be built is using CMake's
45*35238bceSAndroid Build Coastguard Workertarget selection mechanism. For example, the following command will only build
46*35238bceSAndroid Build Coastguard Worker`deqp-vk`, the main Vulkan Conformance Tests binary:
47*35238bceSAndroid Build Coastguard Worker
48*35238bceSAndroid Build Coastguard Worker```
49*35238bceSAndroid Build Coastguard Workercmake --build BUILD_DIRECTORY --target deqp-vk
50*35238bceSAndroid Build Coastguard Worker```
51*35238bceSAndroid Build Coastguard Worker
52*35238bceSAndroid Build Coastguard WorkerWhen building only a subset of targets is the preferred default behavior for a
53*35238bceSAndroid Build Coastguard Workergiven working copy or build directory, there's a second target selection
54*35238bceSAndroid Build Coastguard Workermechanism that can be used to avoid passing the `--target` option every time:
55*35238bceSAndroid Build Coastguard Workerthe `SELECTED_BUILD_TARGETS` CMake option. If set to a non-empty value, only the
56*35238bceSAndroid Build Coastguard Workertargets listed in that configuration option, separated by spaces, will be built.
57*35238bceSAndroid Build Coastguard Worker
58*35238bceSAndroid Build Coastguard WorkerFor example, passing `-DSELECTED_BUILD_TARGETS="deqp-vk deqp-vksc"` when
59*35238bceSAndroid Build Coastguard Workerconfiguring the project will make `cmake --build BUILD_DIRECTORY` act as if it
60*35238bceSAndroid Build Coastguard Workerhad been passed `--target deqp-vk --target deqp-vksc` as additional arguments.
61*35238bceSAndroid Build Coastguard Worker
62*35238bceSAndroid Build Coastguard Worker**IMPORTANT**: Target subset selection may not have been thoroughly tested in
63*35238bceSAndroid Build Coastguard Workerall enviroments and situations, and it does not replace the instructions given
64*35238bceSAndroid Build Coastguard Workerfor the purposes of creating a conformance submission.
65*35238bceSAndroid Build Coastguard Worker
66*35238bceSAndroid Build Coastguard WorkerANGLE for Android
67*35238bceSAndroid Build Coastguard Worker--------------------------------
68*35238bceSAndroid Build Coastguard Worker
69*35238bceSAndroid Build Coastguard WorkerANGLE can be built for Android by following the instructions
70*35238bceSAndroid Build Coastguard Worker[here](https://chromium.googlesource.com/angle/angle.git/+/HEAD/doc/DevSetup.md#building-angle-for-android).
71*35238bceSAndroid Build Coastguard Worker
72*35238bceSAndroid Build Coastguard WorkerThe resulting ANGLE shared object libraries can be linked against and embedded into `dEQP.apk` with
73*35238bceSAndroid Build Coastguard Workerthe `--angle-path` option.   This will cause `dEQP.apk` to use the ANGLE libraries for OpenGL ES
74*35238bceSAndroid Build Coastguard Workercalls, rather than the native drivers.
75*35238bceSAndroid Build Coastguard Worker
76*35238bceSAndroid Build Coastguard WorkerAn ABI must be specified and the directory structure containing the ANGLE shared objects must match
77*35238bceSAndroid Build Coastguard Workerit so the build system can find the correct `*.so` files.
78*35238bceSAndroid Build Coastguard Worker
79*35238bceSAndroid Build Coastguard WorkerAssuming ANGLE shared objects are generated into `~/chromium/src/out/Release/` and `dEQP.apk` will
80*35238bceSAndroid Build Coastguard Workerbe generated with `--abis arm64-v8a`, issue the following commands:
81*35238bceSAndroid Build Coastguard Worker
82*35238bceSAndroid Build Coastguard Worker	cd ~/chromium/src/out/Release/
83*35238bceSAndroid Build Coastguard Worker	mkdir arm64-v8a && cd arm64-v8a
84*35238bceSAndroid Build Coastguard Worker	cp ../lib*_angle.so .
85*35238bceSAndroid Build Coastguard Worker
86*35238bceSAndroid Build Coastguard WorkerThe `--angle-path ~/chromium/src/out/Release/` option can then be used to link against and embed the
87*35238bceSAndroid Build Coastguard WorkerANGLE shared object files.   The full command would be:
88*35238bceSAndroid Build Coastguard Worker
89*35238bceSAndroid Build Coastguard Worker	python scripts/android/build_apk.py --sdk <path to Android SDK> --ndk <path to Android NDK> --abis arm64-v8a --angle-path ~/chromium/src/out/Release/
90