File: rules

package info (click to toggle)
wml 2.0.11ds1-0.4
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 11,000 kB
  • ctags: 5,797
  • sloc: ansic: 54,597; sh: 16,003; perl: 14,804; makefile: 2,308; yacc: 445
file content (76 lines) | stat: -rwxr-xr-x 2,129 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#!/usr/bin/make -f

SHELL = /bin/sh

r = $(shell pwd)/debian/wml
p = wml

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
unexport CFLAGS
unexport CPPFLAGS
unexport LDFLAGS

build: build-stamp
build-stamp:
	dh_testdir
	./configure --prefix=/usr --with-catdir=man --mandir=/usr/share/man
	$(MAKE)
	touch build-stamp

clean:
	dh_testdir
	dh_testroot
	rm -f build-stamp
	# Add here commands to clean up after the build process.
	-$(MAKE) distclean
	dh_clean
	-test -r /usr/share/misc/config.sub && \
	cp -f /usr/share/misc/config.sub etc/config.sub &&\
	cp -f /usr/share/misc/config.sub wml_backend/p2_mp4h/config.sub
	-test -r /usr/share/misc/config.guess && \
	cp -f /usr/share/misc/config.guess etc/config.guess && \
	cp -f /usr/share/misc/config.guess wml_backend/p2_mp4h/config.sub

# Build architecture-independent files here.
binary-indep: build
# There are no architecture-independent files to be uploaded
# generated by this package.  If there were any they would be
# made here.

# Build architecture-dependent files here.
binary-arch: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs
	$(MAKE) prefix=$(r)/usr mandir=$(r)/usr/share/man INSTALLDIRS=perl install
	cd wml_common/filepathconvert && \
		$(MAKE) DESTDIR=$(r) mandir=$(r)/usr/share/man INSTALLDIRS=perl install
	cd wml_common/gd && \
		$(MAKE) DESTDIR=$(r) mandir=$(r)/usr/share/man INSTALLDIRS=perl install
	dh_installdocs ANNOUNCE BUGREPORT COPYRIGHT COPYRIGHT.OTHER CREDITS \
		MANIFEST NEWS README README.mp4h SUPPORT VERSION \
		VERSION.HISTORY wml_contrib/
	find $(r) -name \*.spec | xargs rm -f
	find $(r)/usr -type f -name .packlist | xargs rm -f
	#   Fix documentation
	for f in $(r)/usr/share/man/*/*; do \
	   sed -e 's|.*/\([^/	]*\)	.*/\([^/	]*\)|s/\2/\1/|' debian/links |\
	   sed -f - $$f > $$f.new && mv $$f.new $$f; \
	done
	chmod 644 $(r)/usr/share/man/*/*
	dh_installchangelogs ChangeLog
	dh_strip
	dh_compress
	dh_link
	dh_fixperms
	dh_installdeb
	dh_perl usr/lib/wml/perl/lib
	dh_shlibdeps
	dh_gencontrol
	dh_md5sums
	dh_builddeb

binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary