summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 06ef35dfbc095a34e40b8897c1ba70055cfe0725 (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='ESeries'

pkgname=vcvrack-eseries-git
pkgver=r39.e584aa6
pkgrel=1
pkgdesc="E-Series VCV modules"
url='https://github.com/vcvrack/eseries'
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 {CHANGELOG,README}.md \
    -t "${pkgdir}/usr/share/doc/${pkgname}"
}