File: rules

package info (click to toggle)
libwww-search-perl 2.51.60-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 1,764 kB
  • ctags: 986
  • sloc: perl: 9,906; sh: 132; makefile: 16
file content (28 lines) | stat: -rwxr-xr-x 846 bytes parent folder | download
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
#!/usr/bin/make -f

PKG:=$(shell dh_listpackages)
TMP:=$(CURDIR)/debian/$(PKG)

%:
	dh $@ --with components

override_dh_auto_install:
	dh_auto_install
	sed -i -e'1s/#!\/usr\/local\/bin\/perl/#/' $(TMP)/usr/share/perl5/WWW/Search/*.pm

override_dh_auto_test:
	NO_NETWORK=1 PERL5LIB=blib/lib PATH=blib/script:${PATH} dh_auto_test

override_dh_components:
	dh_components
	mv $(TMP)/usr/bin/googlism.pl $(TMP)/usr/bin/googlism
	mv $(TMP)/usr/share/man/man1/googlism.pl.1p $(TMP)/usr/share/man/man1/googlism.1p

# We had to patch Makefile.PL as otherwise the sub-directory Makefile.PL's 
# are found, run and failed. Then as the patch is unapplied at the end
# Makefile is older than Makefile.PL. Makefile.PL then tries to recreate
# Makefile but is now unpatched.
override_dh_auto_clean:
	if [ -f Makefile ]; then touch Makefile; fi
	dh_auto_clean