summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 8a50e7f6ad275d67e4cf0d491decdad40195aecb (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
55
56
57
# Author: mosra <mosra@centrum.cz>
pkgname=magnum-git
pkgver=2019.01.r345.gb11873b97
pkgrel=1
pkgdesc="C++11/C++14 graphics middleware for games and data visualization (Git version)"
arch=('i686' 'x86_64')
url="https://magnum.graphics"
license=('MIT')
depends=('corrade-git' 'openal' 'glfw' 'sdl2' 'vulkan-icd-loader')
makedepends=('cmake' 'git')
provides=('magnum')
conflicts=('magnum')
source=("git+git://github.com/mosra/magnum.git")
sha1sums=('SKIP')

pkgver() {
    cd "$srcdir/${pkgname%-git}"
    git describe --long | sed -r 's/([^-]*-g)/r\1/;s/-/./g;s/v//g'
}

build() {
    mkdir -p "$srcdir/build"
    cd "$srcdir/build"

    cmake "$srcdir/${pkgname%-git}" \
        -DCMAKE_BUILD_TYPE=Release \
        -DCMAKE_INSTALL_PREFIX=/usr \
        -DWITH_AUDIO=ON \
        -DWITH_VK=ON \
        -DWITH_GLFWAPPLICATION=ON \
        -DWITH_SDL2APPLICATION=ON \
        -DWITH_GLXAPPLICATION=ON \
        -DWITH_WINDOWLESSGLXAPPLICATION=ON \
        -DWITH_GLXCONTEXT=ON \
        -DWITH_OPENGLTESTER=ON \
        -DWITH_ANYAUDIOIMPORTER=ON \
        -DWITH_ANYIMAGECONVERTER=ON \
        -DWITH_ANYIMAGEIMPORTER=ON \
        -DWITH_ANYSCENEIMPORTER=ON \
        -DWITH_MAGNUMFONT=ON \
        -DWITH_MAGNUMFONTCONVERTER=ON \
        -DWITH_OBJIMPORTER=ON \
        -DWITH_TGAIMAGECONVERTER=ON \
        -DWITH_TGAIMPORTER=ON \
        -DWITH_WAVAUDIOIMPORTER=ON \
        -DWITH_DISTANCEFIELDCONVERTER=ON \
        -DWITH_FONTCONVERTER=ON \
        -DWITH_IMAGECONVERTER=ON \
        -DWITH_GL_INFO=ON \
        -DWITH_AL_INFO=ON
    make
}

package() {
    cd "$srcdir/build"
    make DESTDIR="$pkgdir/" install
}