summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 95781c84174ffae177fc1d3be76d2ed02c66624b (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
# Maintainer: Milkii Brewster <milkii on Freenode IRC>
maintaner="Milkii Brewster <milkii on Freenode IRC>"
_pkgname=poly.lv2
pkgname=$_pkgname-git
pkgdesc="A collection of LV2 plugins designed for modular / eurorack style use."
pkgver=r2.3fd1dd4
pkgrel=1
arch=(x86_64)
url="https://github.com/polyeffects/PolyLV2"
license=()
groups=('lv2plugins')
depends=('lv2')
makedepends=('git')
provides=('poly.lv2')
conflicts=('poly.lv2')
source=($pkgname::git+https://github.com/polyeffects/PolyLV2)
md5sums=('SKIP')

pkgver() {
  cd "$pkgname"
  ( set -o pipefail
  git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
  )
}

prepare() {
  cd "$pkgname"
}

build() {
  cd "$pkgname"
  for d in */; do
    cd "$d" && make && cd ..
  done
}

package() {
  cd "$pkgname"
  for d in */; do
    cd "$d"
    find . -type 'f' | grep -v "build" | xargs rm
    cp -r build/* .
    rm -rf build
    cd ..
  done
  mkdir -p "$pkgdir/usr/lib/lv2/"
  cp -r * "$pkgdir/usr/lib/lv2/"
}