1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
|
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
PACKAGE = $(shell dh_listpackages)
TMP = $(CURDIR)/debian/$(PACKAGE)
ARCHLIB := $(shell perl -MConfig -e 'print $$Config{vendorarch}')
export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow
# don't run resource intensive test t/ucd.t on slow arches
DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH)
SLOW_ARCH = armel armhf mips mipsel sparc sparc64 m68k
ifeq (,$(filter $(DEB_HOST_ARCH), $(SLOW_ARCH)))
export TEXT_BIDI_SKIP_UCD=0
else
export TEXT_BIDI_SKIP_UCD=1
endif
%:
dh $@
override_dh_auto_install:
dh_auto_install
# remove if it exists but doesn't not have a size > 0
if [ -e $(TMP)$(ARCHLIB)/auto/Text/Bidi/private/private.bs -a \
! -s $(TMP)$(ARCHLIB)/auto/Text/Bidi/private/private.bs ]; then \
$(RM) -v $(TMP)$(ARCHLIB)/auto/Text/Bidi/private/private.bs; \
fi
# Remove fribidi.pl script, installed as an example instead:
$(RM) -rv $(TMP)/usr/bin
$(RM) -rv $(TMP)/usr/share/man/man1
# remove empty manpage
$(RM) -v $(TMP)/usr/share/man/man3/Text::Bidi::private.3pm
override_dh_installexamples:
dh_installexamples
sed -i '1s|^#!perl|#!/usr/bin/perl|' $(TMP)/usr/share/doc/$(PACKAGE)/examples/*
|