# $Id: PKGBUILD 227981 2014-12-24 07:15:49Z andrea $
# Maintainer: Tom Gundersen <teg@jklm.no>
# Contributor: Andrea Scarpino <andrea@archlinux.org>

pkgname=libbluedevil
pkgver=2.1
pkgrel=1
epoch=1
pkgdesc='A Qt4 wrapper for bluez used in the new KDE bluetooth stack'
arch=('i686' 'x86_64')
url="https://projects.kde.org/projects/playground/libs/libbluedevil"
license=('GPL')
depends=('qt4' 'bluez')
makedepends=('cmake')
source=("http://download.kde.org/stable/${pkgname}/${pkgver}/src/${pkgname}-${pkgver}.tar.xz")
md5sums=('0ffc977d171d786ae34bc4e461fe682b')

prepare() {
  mkdir build
}

build() {
  cd build
  cmake ../${pkgname}-${pkgver} \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DCMAKE_INSTALL_LIBDIR=lib \
    -DQT_QMAKE_EXECUTABLE=/usr/bin/qmake-qt4
  make
}

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