# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI=4

inherit gnome2-utils

DESCRIPTION="Style neutral, scalable cursor theme"
HOMEPAGE="http://www.ubuntu.com"
SRC_URI="mirror://ubuntu/pool/main/d/${PN}/${PN}_${PV}.tar.gz"

LICENSE="CCPL-Attribution-ShareAlike-3.0"
SLOT="0"
KEYWORDS="~amd64 ~x86"

RESTRICT="binchecks strip"

DEPEND="x11-apps/xcursorgen"

src_compile() {
	cd "${S}"/DMZ-Black/pngs && ./make.sh
	cd "${S}"/DMZ-White/pngs && ./make.sh
}

src_install() {
	for th in Black White; do
		insinto /usr/share/icons/DMZ-${th}
		doins DMZ-${th}/*.theme
		insinto /usr/share/icons/DMZ-${th}/cursors
		doins DMZ-${th}/xcursors/*
	done
	dodoc debian/changelog
}

pkg_preinst() {
	gnome2_icon_savelist
}

pkg_postinst() {
	gnome2_icon_cache_update
}

pkg_postrm() {
	gnome2_icon_cache_update
}