# $Id: PKGBUILD 239765 2015-05-26 09:38:49Z arojas $
# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Andrea Scarpino <andrea@archlinux.org>
# Contributor: Antonio Rojas <arojas@archlinux.org>

pkgname=kdecoration
pkgver=5.3.1
pkgrel=1
pkgdesc='Plugin based library to create window decorations'
arch=('i686' 'x86_64')
url='https://projects.kde.org/projects/kde/workspace/kdecoration'
license=('LGPL')
depends=('qt5-base')
makedepends=('extra-cmake-modules')
source=("http://download.kde.org/stable/plasma/$pkgver/$pkgname-$pkgver.tar.xz")
md5sums=('97297617f2a3456e31d56fcd9feac889')

prepare() {
  mkdir build
}

build() {
  cd build
  cmake ../$pkgname-$pkgver \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DLIB_INSTALL_DIR=lib \
    -DSYSCONF_INSTALL_DIR=/etc \
    -DKDE_INSTALL_USE_QT_SYS_PATHS=ON \
    -DBUILD_TESTING=OFF
  make
}

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