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

pkgname=filelight
pkgver=15.04.2
pkgrel=1
pkgdesc='View disk usage information'
url='http://kde.org/applications/utilities/filelight'
arch=('i686' 'x86_64')
license=('GPL' 'LGPL' 'FDL')
depends=('kparts')
makedepends=('extra-cmake-modules' 'kdoctools' 'python')
groups=('kde-applications' 'kdeutils')
replaces=('kdeutils-filelight')
conflicts=('kdeutils-filelight')
install=${pkgname}.install
source=("http://download.kde.org/stable/applications/${pkgver}/src/filelight-${pkgver}.tar.xz")
sha1sums=('9ebdcc2ff872912193a6d8b5844ce89e36615bb0')

prepare() {
  mkdir -p build
}

build() {
  cd build
  cmake ../$pkgname-$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
}
