# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
# Maintainer: Balló György <ballogyor+arch at gmail dot com>
# Contributor: Antonio Rojas <arojas@archlinux.org>
# Contributor: Ionut Biru <ibiru@archlinux.org>
# Contributor: Ju Liu <liuju86 at gmail dot com>
# Contributor: Bjorn Lindeijer <bjorn lindeijer nl>
# Contributor: Andreas Zwinkau <beza1e1@web.de>

pkgname=telepathy-mission-control
pkgver=5.16.6
pkgrel=3
pkgdesc='Account manager and channel dispatcher for Telepathy'
arch=(x86_64 powerpc64le powerpc64 powerpc riscv64)
url='https://telepathy.freedesktop.org/'
license=('LGPL-2.1-only')
depends=('dconf' 'dbus' 'dbus-glib' 'glib2' 'glibc' 'libnm' 'telepathy-glib')
makedepends=('libxslt' 'python')
source=("https://telepathy.freedesktop.org/releases/$pkgname/$pkgname-$pkgver.tar.gz"{,.asc})
sha256sums=('2df8ae3995e919a7670e01aa3568215ef0777e34961ace1cac1c6477cb297a45'
            'SKIP')
validpgpkeys=(38FDAD7D73CE1AE7A16200291F3845DD1432A9FB  # Georgios Kiagiadakis <gkiagia@tolabaki.gr>
              AA33B0D27868E36C151780F0FE0B6D736B1195ED) # Alexandr Akulich <akulichalexander@gmail.com>

build() {
  cd $pkgname-$pkgver
  ./configure --prefix=/usr \
      --libexecdir=/usr/lib/telepathy \
      --with-connectivity=nm
  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
  make
}

check() {
  cd $pkgname-$pkgver
  make check
}

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