# SliTaz package receipt.

PACKAGE="blackbox"
VERSION="0.70.1"
CATEGORY="x-window"
SHORT_DESC="A small, fast, full-featured window manager for X"
MAINTAINER="devl547@gmail.com"
TARBALL="$PACKAGE-$VERSION.tar.bz2"
WEB_SITE="http://blackboxwm.sourceforge.net/"
WGET_URL="$SF_MIRROR/blackboxwm/$TARBALL"

DEPENDS="xorg-libXt xorg-libXft"
BUILD_DEPENDS="xorg-libXt-dev xorg-libXft-dev xorg-xextproto"

# TODO: modify tazx for blackbox so it will creat a correct ~/.xinitrc
# to let user use the wm via slim/F1 or by default with 'tazx blackbox'.

# Rules to configure and make the package.
compile_rules()
{
	cd $src
	patch -p1 < $stuff/blackbox-0.70.1-gcc-4.3.patch
	patch -p0 < $stuff/blackbox-0.70.1-asneeded.patch
	patch -p1 < $stuff/textpropertytostring-unconditional.patch
	./configure --sysconfdir=/etc \
	--libexecdir=/usr/bin --mandir=/usr/share/man \
	$CONFIGURE_ARGS &&
	make &&
	make DESTDIR=$DESTDIR install
}

# Rules to gen a SliTaz package suitable for Tazpkg.
genpkg_rules()
{
	mkdir -p $fs/usr/share
	cp -a $_pkg/usr/bin $fs/usr
	cp -a $_pkg/usr/share/blackbox $fs/usr/share
}