summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: f235c661274795181d2441df3d1dbae61e9987c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# Maintainer: Ryo Munakata <afpacket@gmail.com>
pkgname=glmark2-git
pkgver=r870.b949d5f
pkgrel=1
pkgdesc="OpenGL (ES) 2.0 benchmark (X11, Wayland, DRM)"
arch=('i686' 'x86_64')
url="https://launchpad.net/glmark2"
license=('GPL3')
depends=('libjpeg-turbo' 'libpng12' 'libx11' 'libxcb' 'wayland' 'libgl' 'libgles')
makedepends=('git' 'python2')
conflicts=('glmark2')
provides=('glmark2')
source=(
    "$pkgname"::'git://github.com/glmark2/glmark2.git'
    )
md5sums=(
    'SKIP'
    )

# GLMARK2 features
GM2_FLAVORS="x11-gl,x11-glesv2,wayland-gl,wayland-glesv2,drm-gl,drm-glesv2"

pkgver() {
    cd "${srcdir}/${pkgname}"
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

prepare() {
    cd "${srcdir}/${pkgname}"
}

build() {
    cd "${srcdir}/${pkgname}"
    python2 ./waf configure \
        --prefix=/usr \
        --with-flavors=${GM2_FLAVORS}
    python2 ./waf -j4
}

package() {
    cd "${srcdir}/${pkgname}"
    DESTDIR="${pkgdir}" python2 ./waf install
}