File: rules

package info (click to toggle)
fcheck 2.7.59-7sarge1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 208 kB
  • ctags: 28
  • sloc: perl: 1,077; makefile: 58; sh: 18
file content (77 lines) | stat: -rwxr-xr-x 2,766 bytes parent folder | download | duplicates (2)
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
77
#!/usr/bin/make -f

INSTALL = install
INSTALL_FILE    = $(INSTALL) -p    -o root -g root  -m  644
INSTALL_PROGRAM = $(INSTALL) -p    -o root -g root  -m  755
INSTALL_SCRIPT  = $(INSTALL) -p    -o root -g root  -m  755
INSTALL_DIR     = $(INSTALL) -p -d -o root -g root  -m  755

export DH_COMPAT=1

build: build-stamp
build-stamp:
	dh_testdir

	
	# Add here commands to compile the package.
	#$(MAKE)

	touch build-stamp

clean:
	dh_testdir
	dh_testroot
	rm -f build-stamp

	# Add here commands to clean up after the build process.
	-$(MAKE) clean

	dh_clean

install: build
	dh_testdir
	dh_testroot
	dh_clean -k
	dh_installdirs

	# Add here commands to install the package into debian/tmp.
	$(MAKE) install DESTDIR=`pwd`/debian/tmp


# Build architecture-dependent files here.
binary-arch: build install
# We have nothing to do by default.

# Build architecture-independent files here.
binary-indep: build install
#	dh_testversion
	dh_testdir
	dh_testroot
	$(INSTALL_DIR) -d debian/tmp/usr/share/doc/fcheck
	$(INSTALL_FILE) README README.Debian debian/copyright \
	                   debian/tmp/usr/share/doc/fcheck
	$(INSTALL_DIR) debian/tmp/etc/cron.d
	$(INSTALL_FILE) debian/fcheck.cron.d debian/tmp/etc/cron.d/fcheck

	$(INSTALL_DIR) debian/tmp/usr/share/man/man1
	$(INSTALL_FILE) debian/fcheck.1 debian/tmp/usr/share/man/man1/fcheck.1
	$(INSTALL_FILE) debian/changelog debian/tmp/usr/share/doc/fcheck/changelog.Debian
	cd debian/tmp && gzip -9f usr/share/man/man1/fcheck.1 usr/share/doc/fcheck/README usr/share/doc/fcheck/changelog.Debian
	find debian/tmp  -print0 2>/dev/null | xargs -0r chown --no-dereference 0:0
	find debian/tmp ! -type l  -print0 2>/dev/null | xargs -0r chmod go=rX,u+rw,a-s
	find debian/tmp/usr/share/doc -type f  ! -regex 'debian/tmp/usr/share/doc/[^/]*/examples/.*' -print0 2>/dev/null | xargs -0r chmod 644
	find debian/tmp/usr/share/doc -type d  -print0 2>/dev/null | xargs -0r chmod 755
	find debian/tmp/usr/share/man debian/tmp/usr/man/ debian/tmp/usr/X11*/man/ -type f  -print0 2>/dev/null | xargs -0r chmod 644
	find debian/tmp -perm -5 -type f \( -name '*.so*' -or -name '*.la' -or -name '*.a' \)  -print0 2>/dev/null | xargs -0r chmod 644
	find debian/tmp/usr/include  -type f -name '*.h'  -print0 2>/dev/null | xargs -0r chmod 644
	find debian/tmp/usr/lib/perl5 debian/tmp/usr/share/perl5 -type f -perm -5 -name '*.pm'  -print0 2>/dev/null | xargs -0r chmod a-X
	$(INSTALL_DIR) debian/tmp/DEBIAN
	$(INSTALL_SCRIPT) debian/fcheck.postinst debian/tmp/DEBIAN/postinst
	$(INSTALL_FILE) debian/conffiles debian/tmp/DEBIAN/conffiles
	dpkg-gencontrol -ldebian/changelog -isp -Tdebian/substvars -Pdebian/tmp

	dh_md5sums -v
	dh_builddeb -v

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