summaryrefslogtreecommitdiff
path: root/libre/luxmark/PKGBUILD
blob: 2ffe9673416c451aec01b68651cdb6c0e2c4c183 (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
44
45
46
47
48
49
50
51
52
53
54
# $Id: PKGBUILD 207918 2017-01-18 20:07:48Z stativ $
# Maintainer: Lukas Jirkovsky <l.jirkovsky@gmail.com>
# Maintainer (Hyperbola): Márcio Silva <coadde@hyperbola.info>
# Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe>
pkgname=luxmark
pkgver=3.1
_scenever=3.1beta3
_pkgver=21d445746802
pkgrel=4.parabola2
pkgdesc="OpenCL benchmark tool, with opencl-mesa recommendation"
arch=('x86_64') # because of embree only x86_64 is supported
url="http://www.luxrender.net/"
license=('GPL3')
depends=('boost-libs' 'embree' 'freetype2' 'freeglut' 'glew' 'opencl-icd-loader' 'libgl' 'libpng' 'openimageio' 'qt4')
makedepends=('cmake' 'boost' 'luxrays' 'mesa' 'opencl-headers' 'freeglut')
optdepends=('opencl-mesa: OpenCL support for AMD/ATI GPUs')
source=($pkgname-$pkgver.tar.bz2::https://bitbucket.org/luxrender/luxmark/get/${_pkgver}.tar.bz2 \
        https://bitbucket.org/luxrender/luxmark/downloads/scenes-v${_scenever}.zip \
        fix_includes.diff::https://bitbucket.org/luxrender/luxmark/commits/b7f5c9475c14b91364835d6a253f43400b7d98cb/raw/ \
        system_scenes.diff exepath.diff)
sha256sums=('af1600ebac738188fec092fc4e3f7e3ecdff29ffb9b1cfa656b970e575fb6767'
            'c5b93e682d44dd1a43e61c1d8d131c364dc285ddba70ddd2036c730663f0e875'
            '796aa9c89bbef57d595d2097347a502e9f988790b43fe5911e024ae0707311d0'
            '489cee3660427676eaf657e41b2f9a64eb4b7e1b0163fdf09286435339cf692f'
            '666e48e92e4f9928e8197d4e0365e7ee640adf2ff9fbb5d09586e1951e54667f')

prepare() {
  cd "$srcdir"/luxrender-luxmark-$_pkgver

  patch -Np1 < "$srcdir/system_scenes.diff"
  # fix includes for luxrays 1.6
  patch -Np1 < "$srcdir/fix_includes.diff"
  # fix exepath for the VR mode to work
  patch -Np1 < "$srcdir/exepath.diff"
}

build() {
  cd "$srcdir/luxrender-luxmark-$_pkgver"

  cmake -DCMAKE_INSTALL_PREFIX=/usr \
    -DCMAKE_SKIP_RPATH=ON \
    .
  make
}

package() {
  cd "$srcdir/luxrender-luxmark-$_pkgver"
  install -D -m755 bin/luxmark "$pkgdir"/usr/bin/luxmark

  install -d "$pkgdir/usr/share/luxmark"
  cp -a "$srcdir/scenes" "$pkgdir/usr/share/luxmark"
}

# vim:set ts=2 sw=2 et: