summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 8632dd2aa79aa27a04d7be39ba4e1ec00be56a84 (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
# Maintainer: Christoph Haag <christoph.haag@collabora.com>
 
pkgname="monado-git"
_dirname="monado"
pkgver=21.0.0.r4339.gfcdc20645
pkgrel=1
pkgdesc='The open source OpenXR runtime.'
arch=('i686' 'x86_64')
url='https://monado.dev'
depends=('openxr' 'vulkan-icd-loader' 'libgl' 'wayland' 'xr-hardware' 'libcap' 'libbsd' 'libdrm')
#'doxygen' #When building docs
makedepends=('eigen' 'ninja' 'shaderc' 'cmake' 'git' 'vulkan-headers')
optdepends=('libuvc: optical tracking support'
            'opencv: optical tracking support'
            'onnxruntime: optical hand tracking support'
            'librealsense: intel realsense camera support'
            'libsurvive-git: lighthouse positional tracking support'
            'openhmd: additional hardware support (Oculus Rift, Nolo)'
            'basalt-monado-git: experimental SLAM tracking through basalt'
            'kimera-vio-monado-git: experimental SLAM tracking through kimera'
            'percetto: tracing support for performance debugging')
provides=("openxr-runtime" "monado")
install=monado.install

license=('boost')
source=("$_dirname::git+https://gitlab.freedesktop.org/monado/monado.git#branch=main")
md5sums=('SKIP')

#options=('debug' '!strip')

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

prepare() {
  cd "$_dirname"
}

build() {
  cd "$_dirname"
  cmake \
    -DCMAKE_INSTALL_LIBDIR=lib \
    -DCMAKE_INSTALL_PREFIX=/usr/ \
    -DCMAKE_BUILD_TYPE=RelWithDebInfo \
    -GNinja -B"$srcdir"/"$_dirname"-build
  ninja -C "$srcdir"/"$_dirname"-build
}

package() {
  cd "$_dirname"-build
  DESTDIR="$pkgdir" ninja install
}