File: rules

package info (click to toggle)
arping 2.01-3
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 148 kB
  • ctags: 192
  • sloc: ansic: 1,646; sh: 176; makefile: 113
file content (45 lines) | stat: -rwxr-xr-x 1,283 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
#!/usr/bin/make -f
# debian/rules for arping by Lenart Janos.
# Written from scratch.

pkg = arping
checkdir = test -f $(pkg).c -a -f debian/rules
checkroot = test $$(id -u) = 0

build:
	$(checkdir)
	$(MAKE) arping2
	touch build

clean:
	$(checkdir)
	rm -f build
	-$(MAKE) clean
	rm -rf debian/tmp debian/files* debian/substvars

binary-indep: build

binary-arch: build
	$(checkdir)
	$(checkroot)
	rm -Rf debian/tmp
	install -d debian/tmp/DEBIAN
	install -d debian/tmp/usr/sbin
	install -d debian/tmp/usr/share/doc/$(pkg)/examples
	install -d debian/tmp/usr/share/man/man8
	install -m 0644 debian/copyright debian/tmp/usr/share/doc/$(pkg)
	install -sm 0755 $(pkg) debian/tmp/usr/sbin
	install -m 0755 arping-scan-net.sh debian/tmp/usr/share/doc/$(pkg)/examples
	gzip -9c README >debian/tmp/usr/share/doc/$(pkg)/README.gz
	gzip -9c debian/changelog >debian/tmp/usr/share/doc/$(pkg)/changelog.Debian.gz
	gzip -9c debian/README.Debian >debian/tmp/usr/share/doc/$(pkg)/README.Debian.gz
	gzip -9c < $(pkg).8 > debian/tmp/usr/share/man/man8/$(pkg).8.gz
	dpkg-shlibdeps $(pkg)
	dpkg-gencontrol -isp
	chown -R root.root debian/tmp
	find debian/tmp -type d -exec chmod 0755 '{}' ';'
	dpkg --build debian/tmp ..

binary: binary-indep binary-arch

.PHONY: binary binary-arch binary-indep clean