summaryrefslogtreecommitdiff
path: root/smf-base/debian/rules
blob: 4f5cbc577206e3b528fcb8ea7abcf57a376b0e7c (plain)
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
#!/usr/bin/make -f

export DH_VERBOSE = 1

unpack: unpack-stamp
unpack-stamp:
	dh_testdir
	dh_illumos_gate \
		usr/src/cmd/svc/milestone \
		usr/src/cmd/svc/shell \
		usr/src/man/man5/smf\* \
		usr/src/cmd/svc/dtd/service_bundle.dtd.1 \
		usr/src/man/man4/service_bundle.4
	cp usr/src/cmd/svc/milestone/README.share README
	touch $@

patch: patch-stamp
patch-stamp: unpack-stamp
	dh_testdir
	[ ! -f debian/patches/series ] || QUILT_PATCHES=debian/patches quilt push -a || test $$? = 2
	touch $@

unpatch:
	dh_testdir
	[ ! -f debian/patches/series ] || QUILT_PATCHES=debian/patches quilt pop -a -f || test $$? = 2
	rm -f patch-stamp

install build: patch-stamp unpack-stamp

binary binary-arch binary-indep: binary-stamp
binary-stamp: patch-stamp
	dh_testdir
	dh_testroot
	dh_installdirs
	dh_install
	find debian/smf-base/lib/svc/manifest -type f -name \*.xml -exec \
		svccfg validate {} \;
	dh_installman
	dh_installdocs
	dh_installexamples
	dh_installchangelogs
	dh_link
	dh_compress
	dh_fixperms
	dh_installdeb
	dh_shlibdeps
	dh_gencontrol
	dh_md5sums
	dh_builddeb
	touch $@

clean: unpatch
	dh_testdir
	dh_testroot
	rm -rf usr .pc
	dh_clean README