blob: 7d73bfbf3149d9fefa643917c5a1887afca0023f [file] [log] [blame]
Andrew Geissler748a4832020-07-24 16:24:21 -05001LICENSE = "Apache-2.0"
2LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
3
4SRC_URI = "\
Andrew Geisslerd688a012020-09-18 13:36:00 -05005 git://github.com/KhronosGroup/VK-GL-CTS.git;protocol=https;name=vk-gl-cts;nobranch=1 \
Andrew Geissler748a4832020-07-24 16:24:21 -05006 git://github.com/google/amber;protocol=https;destsuffix=git/external/amber/src;name=amber;branch=main \
Andrew Geissler595f6302022-01-24 19:11:47 +00007 git://github.com/KhronosGroup/glslang.git;protocol=https;destsuffix=git/external/glslang/src;name=glslang;branch=master \
8 git://github.com/KhronosGroup/SPIRV-Headers.git;protocol=https;destsuffix=git/external/spirv-headers/src;name=spirv-headers;branch=master \
9 git://github.com/KhronosGroup/SPIRV-Tools.git;protocol=https;destsuffix=git/external/spirv-tools/src;name=spirv-tools;branch=master \
Andrew Geissler748a4832020-07-24 16:24:21 -050010 https://raw.githubusercontent.com/baldurk/renderdoc/v1.1/renderdoc/api/app/renderdoc_app.h;subdir=git/external/renderdoc/src;name=renderdoc \
11"
12
13S = "${WORKDIR}/git"
14
Andrew Geisslerd688a012020-09-18 13:36:00 -050015SRCREV_FORMAT = "vk-gl-cts_amber_glslang_spirv-headers_spirv-tools"
Andrew Geissler748a4832020-07-24 16:24:21 -050016
17S = "${WORKDIR}/git"
18
Andrew Geisslerbffdb3e2020-08-21 16:13:29 -050019inherit pkgconfig cmake features_check
20
Andrew Geissler5199d832021-09-24 16:47:35 -050021ANY_OF_DISTRO_FEATURES += "opengl wayland"
Andrew Geissler748a4832020-07-24 16:24:21 -050022
Andrew Geissler5199d832021-09-24 16:47:35 -050023DEPENDS += "libpng zlib virtual/libgles2"
Andrew Geissler748a4832020-07-24 16:24:21 -050024
Andrew Geisslerf103a7f2021-05-07 16:09:40 -050025SRC_URI += "file://0001-Workaround-for-GCC-11-uninit-variable-warnings-946.patch;patchdir=external/amber/src \
26 file://0001-Include-limits-header-for-numeric_limits.patch;patchdir=external/vulkancts \
William A. Kennington IIIb95905d2021-06-02 12:40:56 -070027 file://0001-vulkancts.patch \
Andrew Geissler5199d832021-09-24 16:47:35 -050028 file://0001-use-library-sonames-for-linking.patch \
Andrew Geisslerf103a7f2021-05-07 16:09:40 -050029"
30
Patrick Williams213cb262021-08-07 19:21:33 -050031SRC_URI:append:libc-musl = "\
Andrew Geissler748a4832020-07-24 16:24:21 -050032 file://fix-musl.patch \
33"
Patrick Williams213cb262021-08-07 19:21:33 -050034DEPENDS:append:libc-musl = " libexecinfo"
Andrew Geissler748a4832020-07-24 16:24:21 -050035
Patrick Williams213cb262021-08-07 19:21:33 -050036SRC_URI:append:toolchain-clang = "\
Andrew Geissler748a4832020-07-24 16:24:21 -050037 file://fix-clang-private-operator.patch \
38"
39
Andrew Geissler5199d832021-09-24 16:47:35 -050040# The best thing for the user to do is to not specify any of the following
41# PACKAGECONFIGs (i.e. leave it blank) which tells the project to do its own
42# probing and build what it thinks is appropriate.
43# However, if you want, you can specify one of the following PACKAGECONFIGs
44# to override this behaviour.
45PACKAGECONFIG ??= ""
46PACKAGECONFIG[surfaceless] = "-DDEQP_TARGET=surfaceless,,,,,wayland x11_egl x11_glx x11_egl_glx"
47PACKAGECONFIG[wayland] = "-DDEQP_TARGET=wayland,,wayland,,,surfaceless x11_egl x11_glx x11_egl_glx"
48PACKAGECONFIG[x11_egl] = "-DDEQP_TARGET=x11_egl,,virtual/libx11 virtual/egl,,,surfaceless wayland x11_glx x11_egl_glx"
49PACKAGECONFIG[x11_glx] = "-DDEQP_TARGET=x11_glx,,virtual/libx11,,,surfaceless wayland x11_egl x11_egl_glx"
50PACKAGECONFIG[x11_egl_glx] = "-DDEQP_TARGET=x11_glx,,virtual/libx11 virtual/egl,,,surfaceless wayland x11_egl x11_glx"
51
52python __anonymous() {
53 # if the user doesn't specify any PACKAGECONFIG then the cts build system
54 # is going to probe the sysroot to try to figure out what to build
55 # in this case we try to guess whether the user is building for wayland
56 # or x11 and add the required dependencies automatically
57 distrofeatures = (d.getVar("DISTRO_FEATURES") or "")
58 if not bb.utils.contains_any("PACKAGECONFIG", ["surfaceless", "wayland", "x11_egl", "x11_glx", "x11_egl_glx"], True, False, d):
59 if "wayland" in distrofeatures:
60 d.appendVar("DEPENDS", " wayland ")
61 if "x11" in distrofeatures:
62 d.appendVar("DEPENDS", " virtual/libx11 virtual/egl ")
63}
Andrew Geissler748a4832020-07-24 16:24:21 -050064
65CTSDIR = "/usr/lib/${BPN}"
66
Patrick Williams213cb262021-08-07 19:21:33 -050067FILES:${PN} += "${CTSDIR}"