# $Id$
# Maintainer (Arch): Lukas Jirkovsky <l.jirkovsky@gmail.com>
# Contributor (Arch): Mateusz Herych <heniekk@gmail.com>
# Contributor (Arch): Eric Belanger <eric@archlinux.org>
# Contributor (Arch): Darwin Bautista <djclue917@gmail.com>
# Contributor: André Silva <emulatorman@hyperbola.info>

pkgname=soundkonverter
pkgver=3.0.1
pkgrel=1.parabola1
pkgdesc="Front-end to various audio converters, without nonfree faac and mac recommendation"
arch=('x86_64' 'i686' 'armv7h')
url="http://www.kde-apps.org/content/show.php?content=29024"
license=('GPL')
depends=('hicolor-icon-theme' 'kdelibs4support' 'libkcddb' 'taglib')
makedepends=('cmake' 'extra-cmake-modules' 'kdesignerplugin' 'kdoctools')
optdepends=('cdrkit: cdda2wav backend'
            'faad2: faad backend'
            'ffmpeg: ffmpeg backend'
            'flac: flac backend'
            'fluidsynth: flouidsynth backend'
            'lame: lame backend'
            'mplayer: mplayer backend'
            'mp3gain: mp3gain 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')

build() {
  mkdir -p "$srcdir/build"
  cd "$srcdir/build"

  cmake "$srcdir/$pkgname-$pkgver/src" \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DLIB_INSTALL_DIR=lib \
    -DCMAKE_BUILD_TYPE=Release
  make
}

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