summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 53b051b27a032da9cdfefd786d1225adff1a046f (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
# Maintainer: Sebastiaan Lokhorst <sebastiaanlokhorst@gmail.com>

_pkgname=diplib
pkgname="${_pkgname}-git"
pkgver=r2125.dff4c397
pkgrel=1
pkgdesc='Quantitative Image Analysis in C++, MATLAB and Python'
arch=('x86_64')
url='http://www.diplib.org/'
license=('Apache')
depends=('freeglut' 'glfw' 'glew' 'pybind11')
makedepends=('cmake' 'git')
optdepends=('java-runtime=8: DIPjavaio'
            'python: PyDIP'
            'matlab: DIPimage'
            'doxygen: documentation'
            'pandoc: documentation'
            'pandoc-crossref: documentation'
            'texlive-bin: documentation')
provides=($_pkgname)
conflicts=($_pkgname)
source=('git+https://github.com/DIPlib/diplib.git')
md5sums=('SKIP')

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

build() {
    cd "${srcdir}/${_pkgname}"
    mkdir -p build
    cd build
    cmake \
        -DOpenGL_GL_PREFERENCE=GLVND \
        -DCMAKE_INSTALL_PREFIX=/usr \
        -DCMAKE_BUILD_TYPE=Release \
        ..
    make
}

check() {
    cd "${srcdir}/${_pkgname}/build"
    make check
}

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