blob: 99050e704743b645e3239e117213348503ae4b07 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001SUMMARY = "OpenGL (ES) 2.0 benchmark"
2DESCRIPTION = "glmark2 is a benchmark for OpenGL (ES) 2.0. \
3It uses only the subset of the OpenGL 2.0 API that is compatible with OpenGL ES 2.0."
4HOMEPAGE = "https://launchpad.net/glmark2"
5BUGTRACKER = "https://bugs.launchpad.net/glmark2"
6
7LICENSE = "GPLv3+ & SGIv1"
8LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
9 file://COPYING.SGI;beginline=5;md5=269cdab4af6748677acce51d9aa13552"
10
Brad Bishopd7bf8c12018-02-25 22:55:05 -050011DEPENDS = "libpng jpeg udev"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050012
Brad Bishopd7bf8c12018-02-25 22:55:05 -050013PV = "2017.07+${SRCPV}"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050014
Brad Bishopd7bf8c12018-02-25 22:55:05 -050015COMPATIBLE_HOST_rpi = "${@bb.utils.contains('MACHINE_FEATURES', 'vc4graphics', '.*-linux*', 'null', d)}"
16
17SRC_URI = "git://github.com/glmark2/glmark2.git;protocol=https \
18 file://build-Check-packages-to-be-used-by-the-enabled-flavo.patch \
19 file://Fix-configure-for-sqrt-check.patch \
20 file://0001-Fix-clang-warnings.patch \
21 "
22SRCREV = "ed20c633f1926d1dd78e3e89043c85a81302cbe6"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050023
24S = "${WORKDIR}/git"
25
Brad Bishopd7bf8c12018-02-25 22:55:05 -050026inherit waf pkgconfig distro_features_check
27
28REQUIRED_DISTRO_FEATURES += "opengl"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050029
30PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11 opengl', 'x11-gl x11-gles2', '', d)} \
31 ${@bb.utils.contains('DISTRO_FEATURES', 'wayland opengl', 'wayland-gl wayland-gles2', '', d)} \
32 drm-gl drm-gles2"
33
Patrick Williamsddad1a12017-02-23 20:36:32 -060034# Enable C++11 features
35CXXFLAGS += "-std=c++11"
36
Patrick Williamsb48b7b42016-08-17 15:04:38 -050037PACKAGECONFIG[x11-gl] = ",,virtual/libgl virtual/libx11"
38PACKAGECONFIG[x11-gles2] = ",,virtual/libgles2 virtual/libx11"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080039PACKAGECONFIG[drm-gl] = ",,virtual/libgl libdrm virtual/libgbm"
40PACKAGECONFIG[drm-gles2] = ",,virtual/libgles2 libdrm virtual/libgbm"
Patrick Williamsb48b7b42016-08-17 15:04:38 -050041PACKAGECONFIG[wayland-gl] = ",,virtual/libgl wayland"
42PACKAGECONFIG[wayland-gles2] = ",,virtual/libgles2 wayland"
43
44python __anonymous() {
Brad Bishop6e60e8b2018-02-01 10:27:11 -050045 packageconfig = (d.getVar("PACKAGECONFIG") or "").split()
Patrick Williamsb48b7b42016-08-17 15:04:38 -050046 flavors = []
47 if "x11-gles2" in packageconfig:
48 flavors.append("x11-glesv2")
49 if "x11-gl" in packageconfig:
50 flavors.append("x11-gl")
51 if "wayland-gles2" in packageconfig:
52 flavors.append("wayland-glesv2")
53 if "wayland-gl" in packageconfig:
54 flavors.append("wayland-gl")
55 if "drm-gles2" in packageconfig:
56 flavors.append("drm-glesv2")
57 if "drm-gl" in packageconfig:
58 flavors.append("drm-gl")
59 if flavors:
60 d.appendVar("EXTRA_OECONF", " --with-flavors=%s" % ",".join(flavors))
61}
Patrick Williamsddad1a12017-02-23 20:36:32 -060062