# Maintainer: Brad Fanella <cesura@archlinux.org>
# Contributor: Martin Wimpress <code@flexion.org>

pkgname=mate-notification-daemon
pkgver=1.22.0
pkgrel=1
provides=('notification-daemon')
pkgdesc="Notification daemon for MATE"
url="https://mate-desktop.org"
arch=('x86_64')
license=('GPL')
groups=('mate')
depends=('libcanberra' 'libwnck3' 'libnotify')
makedepends=('intltool' 'python')
conflicts=('mate-notification-daemon-gtk3')
replaces=('mate-notification-daemon-gtk3')
source=("https://pub.mate-desktop.org/releases/${pkgver%.*}/${pkgname}-${pkgver}.tar.xz")
sha256sums=('12bc6b95b517396642f25e060bbe3314db2ce9cf14ad3327f1b1950f3febe31b')

build() {
    	cd "${pkgname}-${pkgver}"
    	./configure \
        	--prefix=/usr \
        	--libexecdir=/usr/lib/${pkgname}

    	#https://bugzilla.gnome.org/show_bug.cgi?id=656231
    	sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool

    	make
}

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