summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a3600466ae0075ebf8b3a8601593489ac5a8a26d (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: Christopher Arndt <aur -at- chrisarndt -dot- de>
# Contributor: prettyvanilla <prettyvanilla@posteo.at>
# Contributor: SpepS <dreamspepser at yahoo dot it>

_pkgname=lilv
pkgname=$_pkgname-git
pkgver=0.26.2.r1652.56e1224
pkgrel=1
pkgdesc='A C library interface to the LV2 plug-in standard with Python bindings (git version)'
arch=(x86_64)
url='http://drobilla.net/software/lilv'
license=(ISC 0BSD)
depends=(glibc 'lv2>=1.18.2')
makedepends=(git libsndfile 'serd>=0.30.10' 'sord>=0.16.20' 'sratom>=0.6.10' 'zix>=0.6.0')
optdepends=(
    "bash-completion: completion for bash"
    "libsndfile: lv2apply utility"
    "python: for Python bindings"
    "python-numpy: for Python bindings"
)
provides=($_pkgname "$_pkgname=${pkgver//.r*/}" $_pkgname-docs python-$_pkgname)
conflicts=($_pkgname $_pkgname-docs python-$_pkgname)
source=("$_pkgname::git+https://gitlab.com/lv2/$_pkgname.git")
sha256sums=('SKIP')

pkgver() {
  cd $_pkgname
  local ver=$(grep -E "^\s+version: '[0-9]+\.[0-9]+\.[0-9]+'" meson.build | cut -d "'" -f 2)
  echo $ver.r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)
}

build() {
  arch-meson $_pkgname $_pkgname-build
  meson compile -C $_pkgname-build
}

check() {
  meson test -C $_pkgname-build || echo "Ignoring failing tests"
}

package() {
  depends+=(libserd-0.so libsord-0.so libsratom-0.so libzix-0.so)
  provides+=(liblilv-0.so)
  meson install -C $_pkgname-build --destdir "$pkgdir"
  # license
  install -vDm 644 $_pkgname/LICENSES/* -t "$pkgdir"/usr/share/licenses/$pkgname
  # documentation
  mv -v "$pkgdir"/usr/share/doc/{$_pkgname-0,$pkgname}
  install -vDm 644 $_pkgname/{AUTHORS,NEWS,README.md} -t "$pkgdir"/usr/share/doc/$pkgname
}