3
SOURCE := $(shell dpkg-parsechangelog | sed -ne 's,^Source: *\(.*\)$$,\1,p')
4
VERSION_DEBIAN := $(shell dpkg-parsechangelog | sed -ne 's,^Version: *\(.*\)$$,\1,p')
5
VERSION := $(shell echo "$(VERSION_DEBIAN)" | sed -e 's,^[0-9]*:,,' -e 's,-[^-]*$$,,')
7
# If set to a true value then MakeMaker's prompt function will
8
# always return the default without waiting for user input.
9
export PERL_MM_USE_DEFAULT=1
11
PACKAGE = $(shell dh_listpackages)
17
TMP = $(CURDIR)/debian/$(PACKAGE)
18
TESTDIR =$(CURDIR)/debian/testdir
24
$(PERL) Makefile.PL INSTALLDIRS=vendor
27
HOME=$(TESTDIR) $(MAKE) test
3
BUILDHOME = $(CURDIR)/debian/build
45
$(MAKE) install DESTDIR=$(TMP) PREFIX=/usr
47
[ ! -d $(TMP)/usr/lib/perl5 ] || rmdir --ignore-fail-on-non-empty --parents $(TMP)/usr/lib/perl5
49
# Build architecture-dependent files here.
50
binary-arch: build install
51
# We have nothing to do by default.
53
# Build architecture-independent files here.
54
binary-indep: build install
60
dh_installdocs TODO README
61
dh_installchangelogs Changes
72
binary: binary-indep binary-arch
75
rm -rf $(filter-out .svn .svk debian, $(wildcard * .[^.]*))
77
DIR_ORIG = ../orig/$(SOURCE)-$(VERSION)
78
TAR_ORIG_NAME = $(SOURCE)_$(VERSION).orig.tar.gz
79
TAR_ORIG = $(firstword $(wildcard ../$(TAR_ORIG_NAME)) $(wildcard ../orig/$(TAR_ORIG_NAME)))
82
rsync --delete --exclude debian --exclude .svk --exclude .svn --link-dest=$(DIR_ORIG)/ -a $(DIR_ORIG)/ .
86
$(error Cannot find orig tarball $(TAR_ORIG_NAME))
89
tar -C ../orig -xzf $(TAR_ORIG)
92
.PHONY: build clean binary-indep binary-arch binary
12
override_dh_auto_test:
14
HOME=$(BUILDHOME) dh_auto_test