File: rules

package info (click to toggle)
nbd 1:3.20-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 5,960 kB
  • sloc: ansic: 7,494; sh: 6,496; makefile: 147
file content (34 lines) | stat: -rwxr-xr-x 1,442 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
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode. 
#export DH_VERBOSE=1

DEB_HOST_GNU_SYSTEM := $(shell dpkg-architecture -qDEB_HOST_GNU_SYSTEM)

%:
	dh $@

override_dh_auto_configure: debian/po/templates.pot
	test -f nbd.h
	if [ -d .git ]; then if [ $$(git status --porcelain | tee gitstatus | wc -l) -ne 1 ]; then echo "GIT STATUS:"; echo "==========="; cat gitstatus; exit 1; fi; rm gitstatus; fi
	dh_auto_configure -- --enable-lfs --enable-syslog \
			--prefix=/ --mandir=/usr/share/man

override_dh_install:
	install -d debian/tmp/usr/share/initramfs-tools/scripts/local-top
	install -d debian/tmp/usr/share/initramfs-tools/hooks
	install -d debian/tmp/etc
	install -d debian/tmp/usr/share/nbd-server
	install -d debian/nbd-client-udeb/sbin
	install -m 644 debian/nbd-client.nbdtab debian/tmp/etc/nbdtab
	install -m 755 debian/nbd-client.initrd debian/tmp/usr/share/initramfs-tools/scripts/local-top/nbd
	install -m 755 debian/nbd-client.initramfs-hook debian/tmp/usr/share/initramfs-tools/hooks/nbd
	install -m 644 debian/nbd-server.conf.tmpl debian/tmp/usr/share/nbd-server/nbd-server.conf.tmpl
	install -m 755 debian/tmp/sbin/min-nbd-client debian/nbd-client-udeb/sbin/nbd-client
	dh_install -s

override_dh_installinit:
	dh_installinit -p nbd-client --no-start -- start 41 S . stop 34 0 6 .
	dh_installinit -p nbd-server

debian/po/templates.pot: debian/nbd-client.templates debian/nbd-server.templates
	@debconf-updatepo