#!/usr/bin/make -f

DEB_PYTHON_SYSTEM := pycentral

include /usr/share/cdbs/1/rules/debhelper.mk
include /usr/share/cdbs/1/class/python-distutils.mk
include /usr/share/cdbs/1/rules/simple-patchsys.mk

DEB_DH_INSTALL_SOURCEDIR := debian/tmp
DEB_PYTHON_INSTALL_ARGS_ALL := --no-compile --install-layout=deb

binary-install/checkbox::
	dh_link /etc/checkbox.d usr/share/checkbox/configs

build/checkbox-cli::
	cp debian/checkbox.postrm debian/checkbox-cli.postrm

build/checkbox-gtk::
	cp debian/checkbox.postrm debian/checkbox-gtk.postrm

build/hwtest-cli::
	cp debian/hwtest.postrm debian/hwtest-cli.postrm

build/hwtest-gtk::
	cp debian/hwtest.postrm debian/hwtest-gtk.postrm

binary-install/checkbox-gtk::
	dh_icons -p$(cdbs_curpkg)

clean::
	-find . -name \*.mo -exec rm {} \;
	-rm -f debian/checkbox-cli.postrm debian/checkbox-gtk.postrm
	-rm -f debian/hwtest-cli.postrm debian/hwtest-gtk.postrm
	debconf-updatepo
