# $Id: PKGBUILD 233313 2015-03-10 08:06:06Z fyan $
# Maintainer: Ionut Biru <ibiru@archlinux.org>

pkgname=udisks2
pkgver=2.1.5
pkgrel=1
pkgdesc="Disk Management Service, version 2"
arch=('i686' 'x86_64')
url="http://www.freedesktop.org/wiki/Software/udisks"
license=('GPL2')
depends=('glib2' 'systemd' 'polkit' 'libatasmart' 'util-linux')
makedepends=('intltool' 'docbook-xsl' 'gobject-introspection' 'python2')
optdepends=('parted: partition management'
            'gptfdisk: GUID partition table support'
            'ntfs-3g: NTFS filesystem management support'
            'dosfstools: VFAT filesystem management support')
source=(http://udisks.freedesktop.org/releases/udisks-$pkgver.tar.bz2{,.sign})
sha256sums=('2cfcf560447ea44cba2a683342c7062aaaf35e4eb554bed64ac2dd55a70a5fb6'
            'SKIP')
validpgpkeys=('3DB46B55EFA59D40E6232148D14EF15DAFE11347')  # Martin Pitt

build() {
  cd udisks-$pkgver
  ./configure --prefix=/usr --sysconfdir=/etc \
      --sbindir=/usr/bin \
      --with-systemdsystemunitdir=/usr/lib/systemd/system \
      --localstatedir=/var --disable-static
  make
}

package() {
  cd udisks-$pkgver
  make DESTDIR="$pkgdir" install \
    bash_completiondir=/usr/share/bash-completion/completions
}
