#!/usr/bin/make -f VERSION := $(shell dpkg-parsechangelog|sed -n '/^Version/{s/Version: \(.*\)-[0-9]*$$/\1/;s/+dfsg//p}') DVERSION:= $(VERSION)+dfsg %: dh $@ --parallel override_dh_auto_install: dh_auto_install # icons mkdir $(CURDIR)/debian/icons && cd $(CURDIR)/debian/icons && mkdir 16 22 48 convert $(CURDIR)/debian/critterding.png -scale 16x16 $(CURDIR)/debian/icons/16/critterding.png convert $(CURDIR)/debian/critterding.png -scale 22x22 $(CURDIR)/debian/icons/22/critterding.png convert $(CURDIR)/debian/critterding.png -scale 48x48 $(CURDIR)/debian/icons/48/critterding.png convert $(CURDIR)/debian/critterding.png -scale 32x32 $(CURDIR)/debian/icons/critterding.xpm override_dh_strip: dh_strip --dbg-package=critterding-dbg override_dh_auto_clean: [ ! -f Makefile ] || $(MAKE) distclean find . -name Makefile.in -delete rm -f aclocal.m4 config.* configure depcomp install-sh ltmain.sh missing rm -rf m4 src/utils/ftgl/.deps src/utils/ftgl/Makefile rm -rf $(CURDIR)/debian/icons obj-* TMPDIR=get-orig-source-tmp EMBEDLIBS=dependencies/bullet dependencies/glew dependencies/tinyxml src/utils/ftgl TXZ=critterding_$(DVERSION).orig.tar.xz get-orig-source: mkdir -p $(TMPDIR) uscan --verbose --download-version $(VERSION) --force-download \ --destdir $(TMPDIR) --rename tar jxf $(TMPDIR)/*.bz2 -C $(TMPDIR); rm -f $(TMPDIR)/*.bz2 @echo "\nFollowing paths contain embedded libraries, removing from tarball:" @cd $(TMPDIR)/*/ && for path in $(EMBEDLIBS); do \ echo $$path; rm -rf $$path; \ done @echo Generating tarball... cd $(TMPDIR) && tar -Jcf ../../$(TXZ) * rm -rf $(TMPDIR)