# $Id: PKGBUILD 240575 2015-06-11 12:01:00Z heftig $
# Maintainer: Ionut Biru <ibiru@archlinux.org>

pkgname=evolution-ews
pkgver=3.16.3
pkgrel=1
pkgdesc="MS Exchange integration through Exchange Web Services"
arch=('i686' 'x86_64')
license=('LGPL2.1')
url="https://wiki.gnome.org/Apps/Evolution/EWS"
depends=('libmspack' 'evolution')
makedepends=('intltool' 'gnome-common')
options=('!emptydirs')
source=(http://ftp.gnome.org/pub/gnome/sources/$pkgname/${pkgver:0:4}/$pkgname-$pkgver.tar.xz
        localedir.patch)
sha256sums=('529d3aa62a6d6d129871d005d95f27b433ad7aeb99f48f395347e18fb0586ad0'
            '774bb703f5846c14ed4f098311a5595f2738999afdd616e029bb2b53344ea16a')

prepare() {
  cd $pkgname-$pkgver
  patch -Np1 -i ../localedir.patch
  autoreconf -fvi
}

build() {
  cd $pkgname-$pkgver
  ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
      --libexecdir=/usr/lib/evolution --disable-static
  make
}

package() {
  cd $pkgname-$pkgver
  make DESTDIR="$pkgdir" install
}
