# $Id: PKGBUILD 240076 2015-06-02 07:02:52Z arojas $
# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Andrea Scarpino <andrea@archlinux.org>

pkgname=kdiamond
pkgver=15.04.2
pkgrel=1
pkgdesc="A single player puzzle game"
url="http://kde.org/applications/games/kdiamond/"
arch=('i686' 'x86_64')
license=('GPL' 'LGPL' 'FDL')
groups=('kde-applications' 'kdegames')
depends=('libkdegames' 'knotifyconfig')
makedepends=('extra-cmake-modules' 'python' 'kdoctools')
install=${pkgname}.install
conflicts=('kdegames-kdiamond')
replaces=('kdegames-kdiamond')
source=("http://download.kde.org/stable/applications/${pkgver}/src/kdiamond-${pkgver}.tar.xz")
sha1sums=('c0a38f86c3e7dc88d810027073017585d3c86ce2')

build() {
  mkdir build
  cd build
  cmake ../kdiamond-${pkgver} \
    -DCMAKE_BUILD_TYPE=Release \
    -DBUILD_TESTING=OFF \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DKDE_INSTALL_USE_QT_SYS_PATHS=ON
  make
}

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