]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/blame - util-linux/util-linux.nm
Merge branch 'master' of ssh://git.ipfire.org/pub/git/ipfire-3.x
[people/amarx/ipfire-3.x.git] / util-linux / util-linux.nm
CommitLineData
88b867df 1###############################################################################
802ea3af
MT
2# IPFire.org - An Open Source Firewall Solution #
3# Copyright (C) - IPFire Development Team <info@ipfire.org> #
88b867df
MT
4###############################################################################
5
802ea3af 6name = util-linux
b7923add 7major_ver = 2.21
a10c58dc 8version = %{major_ver}
3d038b51 9release = 2
802ea3af
MT
10
11groups = System/Base
802ea3af
MT
12url = http://kernel.org/~kzak/util-linux/
13license = GPLv2 and GPLv2+ and BSD with advertising and Public Domain
14summary = A collection of basic system utilities.
15
16description
17 The util-linux package contains a large variety of low-level system
18 utilities that are necessary for a Linux system to function. Among
19 others, Util-linux contains the fdisk configuration tool and the login
88b867df 20 program.
802ea3af
MT
21end
22
23source_dl = ftp://ftp.kernel.org/pub/linux/utils/util-linux/v%{major_ver}/
24
25build
26 requires
27 audit-devel
28 gettext
29 libcap-devel
30 libselinux-devel
31 libsepol-devel
32 ncurses-devel
33 pam-devel
34 zlib-devel
35 end
36
37 CFLAGS += \
38 -D_LARGEFILE_SOURCE \
39 -D_LARGEFILE64_SOURCE \
40 -D_FILE_OFFSET_BITS=64
41
42 configure_options += \
802ea3af 43 --disable-wall \
802ea3af
MT
44 --enable-kill \
45 --enable-login-utils \
46 --enable-partx \
47 --enable-write \
48 --enable-libmount-mount \
49 --with-selinux \
50 --with-audit \
51 --disable-makeinstall-chown \
52 --disable-static
53
54 prepare_cmds
55 sed -e 's@etc/adjtime@var/lib/hwclock/adjtime@g' \
56 -i $(grep -rl '/etc/adjtime' .)
57 end
58
59 # Build nolodin
60 build_cmds
61 gcc %{CFLAGS} -o nologin %{DIR_SOURCE}/nologin.c
62 end
63
64 install_cmds
3d038b51 65 mkdir -pv \
802ea3af
MT
66 %{BUILDROOT}/var/lib/hwclock \
67 %{BUILDROOT}/usr/share/man/man8 \
68 %{BUILDROOT}/var/log
69
3d038b51 70 install -m 755 %{DIR_APP}/nologin %{BUILDROOT}%{sbindir}
802ea3af
MT
71 install -m 644 %{DIR_SOURCE}/nologin.8 %{BUILDROOT}/usr/share/man/man8/
72
73 touch %{BUILDROOT}/var/log/lastlog
74
75 # Remove deprecated commands
3d038b51
MT
76 rm -fv %{BUILDROOT}/{%{sbindir},usr/share/man/man*}/{fsck,mkfs}.{bfs,minix}* \
77 %{BUILDROOT}{%{bindir},%{sbindir}}/{chkdupexe,newgrp,vi{gr,pw}} \
78 %{BUILDROOT}%{sbindir}/{sln,shutdown} %{BUILDROOT}%{bindir}/{line,pg}
44ed57ab
MT
79 rm -fv %{BUILDROOT}/usr/share/man/man1/{chkdupexe,line,pg,newgrp}.* \
80 %{BUILDROOT}/usr/share/man/man8/{vipw,vigr}.*
802ea3af
MT
81 rm -fv %{BUILDROOT}/usr/share/getopt/*.tcsh
82
daf779d6 83 # Set capabilities
3d038b51
MT
84 chmod -v -s %{BUILDROOT}%{bindir}/mount
85 setcap CAP_DAC_OVERRIDE,CAP_SYS_ADMIN=ep %{BUILDROOT}%{bindir}/mount
86 chmod -v -s %{BUILDROOT}%{bindir}/umount
87 setcap CAP_DAC_OVERRIDE,CAP_SYS_ADMIN=ep %{BUILDROOT}%{bindir}/umount
802ea3af 88 end
802ea3af 89end
4eb2b603 90
802ea3af
MT
91packages
92 package %{name}
7dffb82f
MT
93 groups += Base
94
95 requires
96 /etc/pam.d/system-auth
97 end
98
3d038b51
MT
99 provides
100 /bin/dmesg
101 /bin/kill
102 /bin/more
103 /bin/mount
104 /bin/umount
105 /sbin/blkid
106 /sbin/blockdev
107 /sbin/findfs
108 /sbin/fsck
109 /sbin/nologin
110 end
111
7dffb82f
MT
112 obsoletes = util-linux-ng
113
114 conflicts
3d038b51 115 filesystem < 002
fc95e010 116 setup < 3.0-2
7dffb82f 117 util-linux-ng
fc95e010 118 sysvinit <= 2.86-2
7dffb82f 119 end
50f0e95a
MT
120
121 preprequires += coreutils
122
123 script postin
124 touch /var/log/lastlog
125
126 # mtab symlink
127 rm -f /etc/mtab
128 ln -s /proc/mounts /etc/mtab
129 end
802ea3af 130 end
44ed57ab 131
802ea3af
MT
132 # Package information for libblkid
133 package libblkid
134 summary = Block device ID library.
135 description
136 This is the block device identification library,
137 part of util-linux.
138 end
1f9bc2f0 139
3d038b51
MT
140 conflicts = filesystem < 002
141
802ea3af 142 files
fc95e010 143 %{libdir}/libblkid.*
802ea3af
MT
144 end
145 end
44ed57ab 146
802ea3af 147 # Package information for libblkid-devel
44ed57ab 148 package libblkid-devel
802ea3af
MT
149 summary = Development library and header of libblkid.
150 description = %{summary}
1f9bc2f0 151
802ea3af 152 files
fc95e010
MT
153 %{includedir}/blkid/
154 %{libdir}/libblkid.so
2a0484c1 155 %{libdir}/pkgconfig/blkid.pc
fc95e010 156 %{mandir}/man3/*blkid*
802ea3af
MT
157 end
158 end
44ed57ab 159
802ea3af
MT
160 # Package information for libuuid
161 package libuuid
162 summary = Universally unique ID library.
163 description
164 This is the universally unique ID library,
165 part of util-linux.
166 end
1f9bc2f0 167
3d038b51
MT
168 conflicts = filesystem < 002
169
802ea3af 170 files
fc95e010 171 %{libdir}/libuuid.*
802ea3af
MT
172 end
173 end
44ed57ab 174
802ea3af
MT
175 # Package information for libuuid-devel
176 package libuuid-devel
177 summary = Development library and header of libuuid.
178 description = %{summary}
1f9bc2f0 179
802ea3af 180 files
fc95e010
MT
181 %{includedir}/uuid/
182 %{libdir}/libuuid.so
2a0484c1 183 %{libdir}/pkgconfig/uuid.pc
fc95e010 184 %{mandir}/man3/*uuid*
802ea3af
MT
185 end
186 end
44ed57ab 187
802ea3af
MT
188 # Package information for libmount
189 package libmount
190 summary = Device mounting library.
191 description
192 This is the device mounting library,
193 part of util-linux.
194 end
1f9bc2f0 195
3d038b51
MT
196 conflicts = filesystem < 002
197
802ea3af 198 files
fc95e010 199 %{libdir}/libmount.*
802ea3af
MT
200 end
201 end
44ed57ab 202
802ea3af
MT
203 # Package information for libmount-devel
204 package libmount-devel
205 summary = Development library and header of libmount.
206 description = %{summary}
1f9bc2f0 207
802ea3af 208 files
fc95e010
MT
209 %{includedir}/mount/
210 %{libdir}/libmount.so
2a0484c1 211 %{libdir}/pkgconfig/mount.pc
fc95e010 212 %{mandir}/man3/*mount*
802ea3af
MT
213 end
214 end
1f9bc2f0
MT
215
216 package %{name}-debuginfo
217 template DEBUGINFO
218 end
802ea3af 219end