summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 8026b38cf84b8bf987bd23c77fdec947fd43ebef (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: Popolon <popolon@popolon.org
# Contributor: Miroslav Koškár <http://mkoskar.com/>

_basename='vcvrack'
_plugname='Befaco'

pkgname=vcvrack-befaco-git
pkgver=r64.5014a93
pkgrel=1
pkgdesc="Befaco VCV modules"
url='https://github.com/vcvrack/befaco'
license=('GPL3')
arch=(i686 x86_64)
depends=(vcvrack)
makedepends=(git)

source=(
    "$_basename-$_plugname::git+https://github.com/$_basename/$_plugname.git"
)
sha256sums=(
    SKIP
)

pkgver() {
    cd "$_basename-$_plugname"
    printf 'r%s.%s' "$(git rev-list --count HEAD)" \
                    "$(git rev-parse --short HEAD)"
}

build() {
  # define RACK_DIR, so Makefile snippets can be found
  export RACK_DIR="/usr/share/vcvrack"
  # define FLAGS, so headers can be included
  export FLAGS="-I/usr/include/vcvrack -I/usr/include/vcvrack/dep"
  # exporting LDFLAGS for libsamplerate, as the Delay module requires it
  export LDFLAGS="$(pkg-config --libs samplerate) ${LDFLAGS}"
  cd "${_basename}-${_plugname}"
  USE_SYSTEM_LIBS=true make
  USE_SYSTEM_LIBS=true make dist
}

package() {
  cd "${_basename}-${_plugname}"
  install -vDm 644 "dist/${_plugname}"*".zip" \
    "${pkgdir}/opt/vcvrack/${_plugname}.zip"
  install -vDm 644 LICENSE-GPLv3.txt -t "${pkgdir}/usr/share/licenses/${pkgname}/"
  install -vDm 644 README.md \
    -t "${pkgdir}/usr/share/doc/${pkgname}"
}