# $Id: PKGBUILD 241607 2015-06-30 21:06:12Z arojas $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Laurent Carlier <lordheavym@gmail.com>
# Contributor: Antonio Rojas <arojas@archlinux.org>

pkgname=telepathy-kde-accounts-kcm
_pkgname=ktp-accounts-kcm
pkgver=15.04.3
pkgrel=1
pkgdesc='KCM Module for configuring Telepathy Instant Messaging Accounts'
arch=('i686' 'x86_64')
url='http://community.kde.org/Real-Time_Communication_and_Collaboration'
license=('GPL')
groups=('kde-applications' 'kdenetwork' 'telepathy-kde')
depends=('telepathy-qt5' 'kaccounts-integration')
makedepends=('extra-cmake-modules' 'intltool')
optdepends=('telepathy-gabble: XMPP/Jabber accounts support' 'telepathy-haze: account types supported by Pidgin/libpurple')
source=("http://download.kde.org/stable/applications/${pkgver}/src/$_pkgname-${pkgver}.tar.xz")
md5sums=('63ee0918afe889ca5380f490353f55f3')

prepare() {
  mkdir -p build
}

build() {
  cd build
  cmake ../$_pkgname-$pkgver \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DCMAKE_BUILD_TYPE=Release \
    -DLIB_INSTALL_DIR=lib \
    -DKDE_INSTALL_USE_QT_SYS_PATHS=ON
  make
}

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