# Maintainer: Antonio Rojas <arojas@archlinux.org>
# Contributor: Lukas Jirkovsky <l.jirkovsky@gmail.com>
# Contributor: Mateusz Herych <heniekk@gmail.com>
# Contributor: Eric Belanger <eric@archlinux.org>
# Contributor: Darwin Bautista <djclue917@gmail.com>

pkgname=soundkonverter
pkgver=3.0.1
pkgrel=5
pkgdesc="Front-end to various audio converters"
arch=(x86_64)
url="https://www.linux-apps.com/content/show.php?content=29024"
license=(GPL)
depends=(hicolor-icon-theme kdelibs4support libkcddb taglib phonon-qt5)
makedepends=(extra-cmake-modules kdesignerplugin kdoctools kinit)
optdepends=('faac: faac backend'
            'faad2: faad backend'
            'ffmpeg: ffmpeg backend'
            'flac: flac backend'
            'fluidsynth: flouidsynth backend'
            'lame: lame backend'
            'mac: mac backend'
            'mplayer: mplayer backend'
            'opus-tools: opus backend'
            'speex: speexenc, speexdec backends'
            'timidity++: midi backend'
            'twolame: twolame backend'
            'vorbisgain: vorbisgain backend'
            'vorbis-tools: vorbis tools backend'
            'wavpack: wavpack backend'
            'sox: sox plugin (change sample rate, various effects)')
source=("$pkgname-$pkgver.tar.gz::https://github.com/dfaust/soundkonverter/archive/v${pkgver}.tar.gz")
sha256sums=('92117f8aff85aac3a336cc0c94f3739aaa2d07ddd741d737dfd4b1571c60a0ce')

prepare() {
  mkdir -p build
}

build() {
  cd build
  cmake ../$pkgname-$pkgver/src
  make
}

package() {
  cd build
  make DESTDIR="$pkgdir" install
}
