blob: 736b7fab4c2b4e61bda77c21d5ce1f03c28ea807 (
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
|
#!/usr/bin/make -f
include /usr/share/dpkg/buildflags.mk
export DH_VERBOSE = 1
# Full builds:
fs := ufs pcfs udfs
# Only mount:
mount := mntfs lofs objfs ctfs tmpfs dev fd proc sharefs hsfs
# fstyp modules:
fstyp := hsfs zfs
unpack: unpack-stamp
unpack-stamp:
dh_testdir
dh_illumos_gate --build \
usr/src/cmd/fs.d \
usr/src/cmd/fstyp \
usr/src/uts/common/fs/ufs/ufs_subr.c \
usr/src/uts/common/fs/ufs/ufs_tables.c \
usr/src/man/man1m/clri\* \
usr/src/man/man1m/fsck\* \
usr/src/man/man1m/fstyp\* \
usr/src/man/man1m/mkfs\* \
usr/src/man/man1m/mount\* \
usr/src/man/man4/vfstab.4 \
usr/src/cmd/initpkg/\*mountall.sh
dh_illumos_gate \
usr/src/lib/Makefile.lib \
# Buggy and unused:
echo > usr/src/Makefile.msg.targ
# Use GNU ld:
sed -i '/LD_ALTEXEC/d' usr/env.sh
echo 'BDIRECT=' >> usr/src/cmd/Makefile.cmd
echo 'MAPFILE.NES=' >> usr/src/cmd/Makefile.cmd
echo 'MAPFILE.PGA=' >> usr/src/cmd/Makefile.cmd
echo 'MAPFILE.NED=' >> usr/src/cmd/Makefile.cmd
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
dirs-stamp: unpack-stamp
. usr/env.sh; mkdir -p \
debian/tmp/usr/bin \
debian/tmp/sbin \
debian/tmp/usr/sbin \
$(mount:%=debian/tmp/usr/lib/fs/%) \
$(fs:%=debian/tmp/usr/lib/fs/%) \
$(fstyp:%=debian/tmp/usr/lib/fs/%) \
touch $@
install: install-stamp
install-stamp: build-stamp
install -m 755 -t debian/tmp/sbin \
usr/src/cmd/fs.d/mount \
usr/src/cmd/fs.d/umount
install -m 755 -t debian/tmp/usr/sbin \
usr/src/cmd/fs.d/fsck
install -m 755 -t debian/tmp/usr/sbin \
usr/src/cmd/fs.d/clri
for f in mkfs dcopy labelit fsdb fssnap; do \
ln -sf clri debian/tmp/usr/sbin/$$f; \
done
install -m 755 usr/src/cmd/initpkg/mountall.sh \
debian/tmp/sbin/mountall
install -m 755 usr/src/cmd/initpkg/umountall.sh \
debian/tmp/sbin/umountall
touch $@
build build-arch build-indep: build-stamp
build-stamp: dirs-stamp patch-stamp
dh_illumos_make --native usr/src/cmd/fs.d -t mount
dh_illumos_make --native usr/src/cmd/fs.d -t umount
dh_illumos_make --native usr/src/cmd/fs.d -t fsck
dh_illumos_make --native usr/src/cmd/fs.d -t clri
dh_illumos_make --native usr/src/cmd/fstyp
dh_illumos_make --native $(fs:%=usr/src/cmd/fs.d/%)
for fs in $(fstyp); do \
dh_illumos_make --native usr/src/cmd/fs.d/$$fs/fstyp ; \
done
for fs in $(mount); do \
if [ -d usr/src/cmd/fs.d/$$fs/mount ]; then \
dh_illumos_make --native usr/src/cmd/fs.d/$$fs/mount ; \
else \
dh_illumos_make --native usr/src/cmd/fs.d/$$fs ; \
fi ; \
done
touch $@
binary binary-arch binary-indep: binary-stamp
binary-stamp: install-stamp
dh_testdir
dh_testroot
dh_installdirs
dh_install --list-missing
dh_strip
dh_installman
dh_installdocs
dh_installexamples
dh_installchangelogs
dh_bash-completion
dh_link
dh_compress
dh_fixperms
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_md5sums
dh_builddeb
touch $@
clean: unpatch
dh_testdir
dh_testroot
dh_clean
rm -rf usr .pc
|