#Packager: George Vlahavas <vlahavas~at~gmail~dot~com>

pkgname=mate-control-center
pkgver=1.26.0
_majorver=`echo $pkgver | cut -d'.' -f1,2`
pkgrel=1gv
source=("http://pub.mate-desktop.org/releases/${_majorver}/mate-control-center-${pkgver}.tar.xz")
docs=("readme" "install" "copying" "changelog" "authors" "news" "todo")
options=('noautodotnew')

doinst() {
# update the mime desktop database
if [ -x /usr/bin/update-desktop-database ]; then
	/usr/bin/update-desktop-database -q
fi
# update the mime database
if [ -x /usr/bin/update-mime-database ]; then
	/usr/bin/update-mime-database usr/share/mime > /dev/null 2>&1
fi
# compile schemas
if [ -x /usr/bin/glib-compile-schemas ]; then
	/usr/bin/glib-compile-schemas usr/share/glib-2.0/schemas > /dev/null 2>&1
fi
}

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"mate-control-center (utilities to configure the MATE desktop)"
"This package contains configuration applets for the MATE desktop,"
"allowing to set accessibility configuration, desktop fonts, keyboard"
"and mouse properties, sound setup, desktop theme and background, user"
"interface properties, screen resolution, and other MATE parameters."
)


build() {
	cd $startdir/src/$pkgname-$pkgver

	./configure \
		--prefix=/usr \
		--libdir=/usr/lib${LIBDIRSUFFIX} \
		--localstatedir=/var \
		--sysconfdir=/etc \
		--disable-schemas-compile \
		--disable-update-mimedb \
		--disable-static \
		--with-gtk=2.0 \
		--build=$arch-slackware-linux
	make -j $numjobs || return 1
	make install DESTDIR=$startdir/pkg
	
	rm $startdir/pkg/usr/share/applications/mimeinfo.cache
} 
