#Packager: George Vlahavas <vlahavas~at~gmail~dot~com>
#
# Needs imagemagick to convert the icon to png format

pkgname=hex-a-hop
pkgver=1.1.0
pkgrel=1gv
source=("http://downloads.sourceforge.net/project/hexahop/hex-a-hop/$pkgver/hex-a-hop-$pkgver.tar.gz" "hex-a-hop.desktop")
docs=("readme" "install" "copying" "changelog" "authors" "news" "todo")
url=http://hexahop.sourceforge.net/

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"hexahop (a hexagonal tile-based puzzle game)"
"Hex-a-Hop is a hexagonal tile-based puzzle game with one simple goal:"
"destroy all green tiles! There are infinite undos and no time limits"
"-- you just have to find a way to destroy all the green tiles and step"
"on a safe tile at the end."
)


build() {
	cd $startdir/src/$pkgname-$pkgver
	./configure --prefix=/usr --libdir=/usr/lib${LIBDIRSUFFIX} --localstatedir=/var --sysconfdir=/etc --build=$arch-slackware-linux
	make || return 1
	make install DESTDIR=$startdir/pkg

	mkdir -p $startdir/pkg/usr/share/applications
	cp $startdir/src/hex-a-hop.desktop $startdir/pkg/usr/share/applications/
	mkdir -p $startdir/pkg/usr/share/icons/hicolor/32x32/apps
	convert data/icon.bmp $startdir/pkg/usr/share/icons/hicolor/32x32/apps/hex-a-hop.png
}