1 # Maintainer: Andreas Radke <andyrtr@archlinux.org>
4 pkgname=('mesa-demos' 'mesa-utils')
8 url="https://www.mesa3d.org/"
10 makedepends=('meson' 'mesa' 'glu' 'freeglut' 'wayland-protocols')
12 source=(https://archive.mesa3d.org/demos/${pkgver}/mesa-demos-${pkgver}.tar.bz2{,.sig}
14 meson-demos_data_dir.patch)
15 sha512sums=('df6a7f09638ca389d6e8bc569e599dcc59c9aa280bcfb95976d83e5cd3edfe74bb3a31f0953956dc16faa540ee5b09990e3377e1341d836fc527e50ace6e60b8'
17 '25da77914dded10c1f432ebcbf29941124138824ceecaf1367b3deedafaecabc082d463abcfa3d15abff59f177491472b505bcb5ba0c4a51bb6b93b4721a23c2'
18 'fe5cedcb4ecee4d792ea1e3fa8724ca65b8528babd0e3207ee4a584aa27509cd7f65ed4ef08335c5e220cfb9216f2c20c3b1da1a3d7a9cce3f7192908430d8c5')
19 #validpgpkeys=('E390B9700582FAEA959ACAD41EEF53D38A3A9C67') # "Andreas Boll <andreas.boll.dev@gmail.com>"
20 validpgpkeys=('FF4CF638C624C3CF21ED2CF227EF763A2AA39F96') # Erik Faye-Lund <erik.faye-lund@collabora.com>
23 cd ${pkgname}-${pkgver}
24 # FS#75063 - https://gitlab.freedesktop.org/mesa/demos/-/issues/26
25 patch -Np1 -i ../meson-demos_data_dir.patch
30 arch-meson mesa-demos-$pkgver build \
32 -D with-system-data-files=true
37 meson compile -C build
41 meson test -C build --print-errorlogs
44 package_mesa-demos() {
46 depends=('libgl' 'glu' 'freeglut')
47 install=mesa-demos.install
49 DESTDIR="$pkgdir" meson install -C build
51 # add missing egl files
52 install -m 0755 build/src/egl/opengl/{eglgears_wayland,eglgears_x11,eglkms,egltri_wayland,egltri_x11,peglgears,xeglgears,xeglthreads} "${pkgdir}/usr/bin/"
55 rm "${pkgdir}"/usr/bin/{glxinfo,glxgears,eglinfo}
57 install -Dm 0644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}/"
60 package_mesa-utils() {
61 pkgdesc="Essential Mesa utilities"
63 provides=('glxinfo' 'glxgears' 'eglinfo')
66 install -Dm 0755 build/src/egl/opengl/eglinfo -t "${pkgdir}/usr/bin/"
67 install -Dm 0755 build/src/xdemos/{glxinfo,glxgears} -t "${pkgdir}/usr/bin/"
69 install -Dm 0644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}/"