#!/usr/bin/make -f export QT_SELECT := 5 include /usr/share/dpkg/pkg-info.mk %: # dh $@ --with python2,python3 --buildsystem=pybuild dh $@ --with python3 --buildsystem=pybuild override_dh_auto_build: dh_auto_build (for i in $(CURDIR)/qtqr_*.ts; do lrelease -nounfinished $$i -qm $$(echo $$i | sed -e 's/ts$$/qm/g'); done) override_dh_auto_install: dh_auto_install install -m 644 $(CURDIR)/qtqr.py $(CURDIR)/debian/qtqr/usr/bin/qtqr install -m 644 $(CURDIR)/icon.png $(CURDIR)/debian/qtqr/usr/share/pixmaps/qtqr.png override_dh_auto_clean: dh_auto_clean echo $(DEB_VERSION_UPSTREAM) rm -rf $(CURDIR)/build find -name "*.qm" | xargs rm -f PACKAGE = qr-tools BZR_REVISION := $(shell echo $(DEB_VERSION_UPSTREAM) | awk -F"~" '{ print $$2 }' | sed 's/bzr//' ) TARBALL = $(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig.tar .PHONY: get-orig-source get-orig-source: echo $(DEB_VERSION_UPSTREAM) bzr export $(CURDIR)/$(TARBALL) -r $(BZR_REVISION) "lp:qr-tools" tar xf $(CURDIR)/$(TARBALL) find $(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig -name "*.qm" | xargs rm -f find $(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig -name "*.old" | xargs rm -f tar cf $(CURDIR)/$(TARBALL) $(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig xz -9 $(CURDIR)/$(TARBALL) rm -rf $(PACKAGE)_$(DEB_VERSION_UPSTREAM).orig echo " "$(TARBALL).xz" created; move it to the right destination to build the package"