#!/usr/bin/make -f

include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/makefile.mk

DEB_MAKE_INSTALL_TARGET=install DESTDIR=$(DEB_DESTDIR)

DISTRO := $(shell lsb_release -si)

# Anyway, defaults to Debian
ifeq ($(DISTRO),)
DISTRO := Debian
endif

clean::
	@echo "=== Building for distribution: $(DISTRO) ==="
	if [ -d debian/$(DISTRO) ]; then \
	    find debian/$(DISTRO) -name '*.png' | xargs rm -fv; \
	fi

build:
	@echo "=== Installing distribution specific overrides ==="
	if [ -d debian/$(DISTRO) ]; then \
	    find debian/$(DISTRO) -name '*.sng' | xargs sng; \
	fi

#binary-post-install/human-icon-theme::
#	dh_icons
#
#       replace the Ubuntu logos with the distribution overrides
#	if [ -d debian/$(DISTRO) ]; then \
#	    cp -rvf debian/$(DISTRO)/* debian/human-icon-theme/usr/share/icons/Human/; \
#	fi

