# Maintainer: David Runge <dave@sleepmap.de>
_name=infamousPlugins
pkgname=infamousplugins
pkgver=0.3.0
pkgrel=1
pkgdesc="A collection of open-source LV2 plugins"
arch=('x86_64')
url="https://ssj71.github.io/infamousPlugins/"
license=('GPL2')
groups=('lv2-plugins' 'pro-audio')
depends=('fftw' 'ntk' 'zita-resampler')
makedepends=('cmake' 'lv2')
source=("$pkgname-$pkgver.tar.gz::https://github.com/ssj71/${_name}/archive/v${pkgver}.tar.gz")
sha512sums=('54a691bd5a1e0d5274c74d3de3c1dc77c6998bd588a315b6b39de67a78651c6fcb412c527b7a6083666b2ba8aad39e3b32b6efbd6bb12c96653ddbe76524dbbb')

prepare() {
  mv -v "${_name}-${pkgver}" "${pkgname}-${pkgver}"
  cd "${pkgname}-${pkgver}"
  mkdir -v build
}

build() {
  cd "$pkgname-$pkgver/build"
  cmake -DCMAKE_INSTALL_PREFIX=/usr \
        -DCMAKE_BUILD_TYPE=Release \
        ..
  make
}

package() {
  cd "$pkgname-$pkgver/build"
  make DESTDIR="$pkgdir/" install
  install -vDm 644 ../{CHANGELOG,README} \
    -t "${pkgdir}/usr/share/doc/${pkgname}/"
}
