1 |
%define mainver 2.22 |
2 |
%define rc_ver 0 |
3 |
%define rel 4 |
4 |
%if %{rc_ver} |
5 |
%define release %mkrel 0.rc%{rc_ver}.%{rel} |
6 |
%define tarname %{name}-%{version}-rc%{rc_ver} |
7 |
%define distname %{tarname} |
8 |
%else |
9 |
%define release %mkrel %{rel} |
10 |
%define tarname %{name}-%{version} |
11 |
%define distname %{tarname} |
12 |
%endif |
13 |
|
14 |
%define lib_blkid_major 1 |
15 |
%define lib_blkid %mklibname blkid %{lib_blkid_major} |
16 |
%define lib_blkid_devel %mklibname blkid -d |
17 |
|
18 |
%define lib_uuid_major 1 |
19 |
%define lib_uuid %mklibname uuid %{lib_uuid_major} |
20 |
%define lib_uuid_devel %mklibname uuid -d |
21 |
|
22 |
%define lib_ext2fs %mklibname ext2fs 2 |
23 |
%define lib_ext2fs_devel %mklibname ext2fs -d |
24 |
|
25 |
%define lib_mount_major 1 |
26 |
%define lib_mount %mklibname mount %{lib_mount_major} |
27 |
%define lib_mount_devel %mklibname mount -d |
28 |
|
29 |
%define git_url git://git.kernel.org/pub/scm/utils/util-linux/util-linux.git |
30 |
|
31 |
%define build_bootstrap 0 |
32 |
|
33 |
%if !%{build_bootstrap} |
34 |
%bcond_with uclibc |
35 |
%endif |
36 |
|
37 |
%define mtab_symlink 1 |
38 |
|
39 |
### Header |
40 |
Summary: A collection of basic system utilities |
41 |
Name: util-linux |
42 |
Version: 2.22.2 |
43 |
Release: %{release} |
44 |
License: GPLv2 and GPLv2+ and GPLv3+ and LGPLv2+ and BSD with advertising and Public Domain |
45 |
Group: System/Base |
46 |
URL: ftp://ftp.kernel.org/pub/linux/utils/util-linux |
47 |
|
48 |
### Features |
49 |
%define include_raw 1 |
50 |
### Macros |
51 |
%define no_hwclock_archs s390 s390x |
52 |
|
53 |
### Dependences |
54 |
BuildRequires: gcc |
55 |
BuildRequires: sed |
56 |
%if !%{build_bootstrap} |
57 |
BuildRequires: e2fsprogs-devel >= 1.41.6-2 |
58 |
%endif |
59 |
BuildRequires: gettext-devel |
60 |
BuildRequires: pam-devel |
61 |
BuildRequires: ncurses-devel |
62 |
BuildRequires: ncursesw-devel |
63 |
BuildRequires: termcap-devel |
64 |
BuildRequires: texinfo |
65 |
BuildRequires: slang-devel |
66 |
BuildRequires: zlib-devel |
67 |
BuildRequires: libaudit-devel |
68 |
BuildRequires: pkgconfig(systemd) |
69 |
%if %{with uclibc} |
70 |
BuildRequires: uClibc-devel |
71 |
%endif |
72 |
BuildRequires: libtool |
73 |
|
74 |
### Sources |
75 |
Source0: ftp://ftp.kernel.org/pub/linux/utils/%name/v%mainver/%{tarname}.tar.xz |
76 |
# based on Fedora pam files, with pam_selinux stripped out |
77 |
Source1: util-linux-ng-login.pamd |
78 |
Source2: util-linux-ng-remote.pamd |
79 |
Source3: util-linux-ng-chsh-chfn.pamd |
80 |
Source4: util-linux-ng-60-raw.rules |
81 |
Source5: su.pamd |
82 |
Source6: su-l.pamd |
83 |
Source8: nologin.c |
84 |
Source9: nologin.8 |
85 |
Source10: uuidd-tmpfiles.conf |
86 |
|
87 |
### Obsoletes & Conflicts & Provides |
88 |
# fork and rename from util-linux to util-linux-ng |
89 |
Obsoletes: util-linux-ng < 2.19 |
90 |
Obsoletes: util-linux <= 2.13-0.pre7.6 |
91 |
Provides: util-linux = %{version}-%{release} |
92 |
Provides: util-linux-ng = %{version}-%{release} |
93 |
# old versions of e2fsprogs provides blkid / uuidd |
94 |
Conflicts: e2fsprogs < 1.41.8-2 |
95 |
# eject used to be a separate package. 2.1.5 was the last released version, |
96 |
# eject was merged into util-linux 2.22, so our %version is guaranteed to |
97 |
# be bigger than the last eject's |
98 |
Obsoletes: eject |
99 |
Provides: eject = %{version}-%{release} |
100 |
%ifarch alpha %{sunsparc} ppc |
101 |
Obsoletes: clock < %{version}-%{release} |
102 |
%endif |
103 |
|
104 |
Requires(pre): filesystem >= 2.1.9-18 |
105 |
Requires(preun): info-install |
106 |
Requires(post): info-install |
107 |
Requires(pre): mktemp |
108 |
# for /bin/awk |
109 |
Requires(pre): gawk |
110 |
# for /usr/bin/cmp |
111 |
Requires(pre): diffutils |
112 |
Requires(pre): coreutils |
113 |
# conflicts on older coreutils dues to su move: |
114 |
Conflicts: coreutils < 8.19 |
115 |
# conflicts on older sysvinit-legacy-tools due to sulogin & utmpdump move: |
116 |
Conflicts: sysvinit-legacy-tools < 2.87-18 |
117 |
Requires: pam >= 0.66-4 |
118 |
Requires: shadow-utils >= 2:4.1.5 |
119 |
Conflicts: shadow-utils < 2:4.1.5 |
120 |
Requires: %{lib_blkid} = %{version}-%{release} |
121 |
Requires: %{lib_mount} = %{version}-%{release} |
122 |
Requires: %{lib_uuid} = %{version}-%{release} |
123 |
%if %{include_raw} |
124 |
Requires: udev |
125 |
%endif |
126 |
|
127 |
# RHEL/Fedora specific mount options |
128 |
Patch1: util-linux-2.22-mount-managed.patch |
129 |
# add note about ATAPI IDE floppy to fdformat.8 |
130 |
Patch3: util-linux-ng-2.20.1-fdformat-man-ide.patch |
131 |
# 151635 - makeing /var/log/lastlog |
132 |
Patch5: util-linux-ng-2.21-login-lastlog.patch |
133 |
# 231192 - ipcs is not printing correct values on pLinux |
134 |
Patch8: util-linux-ng-2.21-ipcs-32bit.patch |
135 |
# /etc/blkid.tab --> /etc/blkid/blkid.tab |
136 |
Patch11: util-linux-ng-2.16-blkid-cachefile.patch |
137 |
|
138 |
### Mageia Specific patches |
139 |
|
140 |
# misc documentation fixes for man pages |
141 |
Patch111: util-linux-2.11t-mkfsman.patch |
142 |
# (tv) useless???: |
143 |
Patch114: util-linux-2.22-dumboctal.patch |
144 |
Patch115: util-linux-2.22-fix-ioctl.patch |
145 |
Patch116: util-linux-2.12q-autodav.patch |
146 |
|
147 |
# crypto patches |
148 |
# loop-AES patch |
149 |
# reworked from http://loop-aes.sourceforge.net/updates/util-linux-ng-2.17-20100120.diff.bz2 |
150 |
Patch1100: util-linux-2.19.1-loopAES.patch |
151 |
Patch1101: util-linux-2.12q-swapon-skip-encrypted.patch |
152 |
Patch1102: util-linux-2.12-lower-LOOP_PASSWORD_MIN_LENGTH-for-AES.patch |
153 |
# load cryptoloop and cypher modules when use cryptoapi |
154 |
Patch1103: util-linux-2.12a-cryptoapi-load-module.patch |
155 |
Patch1104: util-linux-ng-2.14.1-set-as-encrypted.patch |
156 |
|
157 |
# clock program for ppc |
158 |
Patch1200: util-linux-2.10r-clock-1.1-ppc.patch |
159 |
# leng options for clock-ppc |
160 |
Patch1201: util-linux-2.10s-clock-syntax-ppc.patch |
161 |
# Added r & w options to chfn (lsb mandate) |
162 |
Patch1202: util-linux-2.21-chfn-lsb-usergroups.patch |
163 |
# fix build on alpha with newer kernel-headers |
164 |
Patch1203: util-linux-2.11m-cmos-alpha.patch |
165 |
# do not hide users option in mtab |
166 |
Patch1207: util-linux-ng-2.14.1-users.patch |
167 |
# remove mode= from udf mounts (architecture done so that more may come) |
168 |
Patch1218: util-linux-ng-2.13-mount-remove-silly-options-in-auto.patch |
169 |
# (misc) enable option -x on fsck.cramfs , bug 48224 |
170 |
Patch1219: util-linux-ng-enable_fsck_cramfs.diff |
171 |
# (cg) Fix path parsing in login.defs |
172 |
Patch1220: util-linux-2.21-login-defs-path.patch |
173 |
# (lm) fix default paths after UsrMove (remove /bin and /sbin) |
174 |
Patch1221: util-linux-2.22.1-fix-default-paths-after-UsrMove.patch |
175 |
# Mandrivamove patches |
176 |
Patch1300: util-linux-ng-2.18-losetup-try-LOOP_CHANGE_FD-when-loop-already-busy.patch |
177 |
|
178 |
%description |
179 |
The util-linux package contains a large variety of low-level system |
180 |
utilities that are necessary for a Linux system to function. Among |
181 |
others, Util-linux contains the fdisk configuration tool and the login |
182 |
program. |
183 |
|
184 |
%package -n %{lib_blkid} |
185 |
Summary: Block device ID library |
186 |
Group: System/Libraries |
187 |
License: LGPLv2+ |
188 |
Requires(pre): filesystem >= 2.1.9-18 |
189 |
Conflicts: %{lib_ext2fs} < 1.41.6-2 |
190 |
|
191 |
%description -n %{lib_blkid} |
192 |
This is block device identification library, part of util-linux. |
193 |
|
194 |
%package -n %{lib_blkid_devel} |
195 |
Summary: Block device ID library |
196 |
Group: Development/C |
197 |
License: LGPLv2+ |
198 |
Requires: %{lib_blkid} = %{version}-%{release} |
199 |
Conflicts: %{lib_ext2fs_devel} < 1.41.6-2 |
200 |
Provides: libblkid-devel = %{version}-%{release} |
201 |
|
202 |
%description -n %{lib_blkid_devel} |
203 |
This is the block device identification development library and headers, |
204 |
part of util-linux. |
205 |
|
206 |
%package -n %{lib_uuid} |
207 |
Summary: Universally unique ID library |
208 |
Group: System/Libraries |
209 |
License: BSD |
210 |
Requires(pre): filesystem >= 2.1.9-18 |
211 |
Conflicts: %{lib_ext2fs} < 1.41.8-2 |
212 |
|
213 |
%description -n %{lib_uuid} |
214 |
This is the universally unique ID library, part of e2fsprogs. |
215 |
|
216 |
The libuuid library generates and parses 128-bit universally unique |
217 |
id's (UUID's).A UUID is an identifier that is unique across both |
218 |
space and time, with respect to the space of all UUIDs. A UUID can |
219 |
be used for multiple purposes, from tagging objects with an extremely |
220 |
short lifetime, to reliably identifying very persistent objects |
221 |
across a network. |
222 |
|
223 |
%package -n %{lib_uuid_devel} |
224 |
Summary: Universally unique ID library |
225 |
Group: Development/C |
226 |
License: BSD |
227 |
Conflicts: %{lib_ext2fs} < 1.41.8-2 |
228 |
Requires: %{lib_uuid} = %{version} |
229 |
Provides: libuuid-devel = %{version}-%{release} |
230 |
Conflicts: ossp_uuid-devel |
231 |
|
232 |
%description -n %{lib_uuid_devel} |
233 |
This is the universally unique ID development library and headers, |
234 |
part of e2fsprogs. |
235 |
|
236 |
The libuuid library generates and parses 128-bit universally unique |
237 |
id's (UUID's).A UUID is an identifier that is unique across both |
238 |
space and time, with respect to the space of all UUIDs. A UUID can |
239 |
be used for multiple purposes, from tagging objects with an extremely |
240 |
short lifetime, to reliably identifying very persistent objects |
241 |
across a network. |
242 |
|
243 |
%package -n uuidd |
244 |
Summary: Helper daemon to guarantee uniqueness of time-based UUIDs |
245 |
Group: System/Servers |
246 |
License: GPLv2 |
247 |
Requires(post): systemd >= %{systemd_required_version} |
248 |
Requires(pre): rpm-helper |
249 |
Requires(post): rpm-helper |
250 |
Requires(preun): rpm-helper |
251 |
Requires(postun): rpm-helper |
252 |
Requires(pre): shadow-utils |
253 |
|
254 |
%description -n uuidd |
255 |
The uuidd package contains a userspace daemon (uuidd) which guarantees |
256 |
uniqueness of time-based UUID generation even at very high rates on |
257 |
SMP systems. |
258 |
|
259 |
%package -n %{lib_mount} |
260 |
Summary: Universal mount library |
261 |
Group: System/Libraries |
262 |
License: LGPL2+ |
263 |
Requires(pre): filesystem >= 2.1.9-18 |
264 |
|
265 |
%description -n %{lib_mount} |
266 |
The libmount library is used to parse /etc/fstab, |
267 |
/etc/mtab and /proc/self/mountinfo files, |
268 |
manage the mtab file, evaluate mount options, etc. |
269 |
|
270 |
%package -n %{lib_mount_devel} |
271 |
Summary: Universally unique ID library |
272 |
Group: Development/C |
273 |
License: LGPL2+ |
274 |
Requires: %{lib_mount} = %{version}-%{release} |
275 |
Provides: libmount-devel = %{version}-%{release} |
276 |
|
277 |
%description -n %{lib_mount_devel} |
278 |
Development files and headers for libmount library. |
279 |
|
280 |
%prep |
281 |
%setup -q -n %{distname} |
282 |
cp %{SOURCE8} %{SOURCE9} . |
283 |
|
284 |
%patch1 -p1 |
285 |
%patch3 -p1 |
286 |
%patch5 -p1 |
287 |
%patch8 -p1 -b .p8 |
288 |
|
289 |
%ifarch ppc |
290 |
%patch1200 -p0 |
291 |
%patch1201 -p1 |
292 |
%endif |
293 |
|
294 |
#LSB (sb) |
295 |
%patch1202 -p1 |
296 |
|
297 |
#fix build on alpha with newer kernel-headers |
298 |
%ifarch alpha |
299 |
%patch1203 -p1 |
300 |
%endif |
301 |
|
302 |
%patch111 -p1 -b .mkfsman |
303 |
%patch114 -p0 -b .dumboctal |
304 |
%patch115 -p1 -b .fix-ioctl |
305 |
#%patch116 -p0 -b .autodav |
306 |
|
307 |
#%patch1100 -p1 -b .loopAES |
308 |
#%patch1101 -p0 -b .swapon-encrypted |
309 |
#%patch1102 -p0 -b .loopAES-password |
310 |
#%patch1103 -p0 -b .load-module |
311 |
#%patch1104 -p1 -b .set-as-encrypted |
312 |
|
313 |
#%patch1300 -p1 -b .CHANGE-FD |
314 |
|
315 |
#patch1207 -p1 -b .users |
316 |
# FIXME: double-check if this is really obsoleted by the mount rewrite |
317 |
#patch1218 -p1 -b .silly |
318 |
%patch1219 -p0 |
319 |
#%patch1220 -p1 -b .login-defs |
320 |
%patch1221 -p1 -b .UsrMove |
321 |
|
322 |
# rebuild build system for loop-AES patch |
323 |
./autogen.sh |
324 |
|
325 |
%build |
326 |
%serverbuild |
327 |
unset LINGUAS || : |
328 |
|
329 |
# CFLAGS |
330 |
%define make_cflags -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 |
331 |
|
332 |
export CONFIGURE_TOP="`pwd`" |
333 |
|
334 |
%if %{with uclibc} |
335 |
mkdir -p uclibc |
336 |
pushd uclibc |
337 |
%configure2_5x CC="%{uclibc_cc}" \ |
338 |
CFLAGS="%{uclibc_cflags} %{make_cflags}" \ |
339 |
--enable-shared=no \ |
340 |
--enable-static=yes \ |
341 |
--enable-chfn-chsh \ |
342 |
--without-ncurses |
343 |
|
344 |
%make -C libblkid |
345 |
popd |
346 |
%endif |
347 |
|
348 |
mkdir -p system |
349 |
pushd system |
350 |
export CFLAGS="%{make_cflags} %{optflags} -Os" |
351 |
%configure2_5x \ |
352 |
--disable-wall \ |
353 |
--enable-partx \ |
354 |
--enable-login-utils \ |
355 |
--enable-kill \ |
356 |
--enable-write \ |
357 |
--enable-arch \ |
358 |
--enable-ddate \ |
359 |
--disable-mountpoint \ |
360 |
%if %{include_raw} |
361 |
--enable-raw \ |
362 |
%endif |
363 |
--disable-makeinstall-chown \ |
364 |
--disable-rpath \ |
365 |
--with-audit \ |
366 |
--enable-chfn-chsh |
367 |
|
368 |
# build util-linux |
369 |
%make |
370 |
|
371 |
popd |
372 |
|
373 |
# build nologin |
374 |
gcc %{optflags} %{ldflags} -o nologin nologin.c |
375 |
|
376 |
%ifarch ppc |
377 |
gcc clock-ppc.c %{ldflags} -o clock-ppc |
378 |
%endif |
379 |
|
380 |
%install |
381 |
rm -rf %{buildroot} |
382 |
mkdir -p %{buildroot}%{_bindir} |
383 |
mkdir -p %{buildroot}%{_infodir} |
384 |
mkdir -p %{buildroot}%{_mandir}/man{1,6,8,5} |
385 |
mkdir -p %{buildroot}%{_sbindir} |
386 |
mkdir -p %{buildroot}%{_sysconfdir}/{pam.d,security/console.apps,blkid} |
387 |
|
388 |
%if %{with uclibc} |
389 |
for lib in `find uclibc -name libblkid.a -o -name libuuid.a`; do |
390 |
install -m644 $lib -D %{buildroot}%{uclibc_root}%{_libdir}/$(basename $lib) |
391 |
done |
392 |
%endif |
393 |
|
394 |
# install util-linux |
395 |
%makeinstall_std -C system install DESTDIR=%{buildroot} MANDIR=%{buildroot}/%{_mandir} INFODIR=%{buildroot}/%{_infodir} |
396 |
|
397 |
# install nologin |
398 |
install -m 755 nologin %{buildroot}%{_sbindir} |
399 |
install -m 644 nologin.8 %{buildroot}%{_mandir}/man8 |
400 |
|
401 |
%if %{include_raw} |
402 |
echo '.so man8/raw.8' > %{buildroot}%{_mandir}/man8/rawdevices.8 |
403 |
# see RH bugzilla #216664 |
404 |
install -D -p -m 644 %{SOURCE4} %{buildroot}%{_udevrulesdir}/60-raw.rules |
405 |
%endif |
406 |
|
407 |
# Correct mail spool path. |
408 |
perl -pi -e 's,/usr/spool/mail,/var/spool/mail,' %{buildroot}%{_mandir}/man1/login.1 |
409 |
|
410 |
%ifarch %{sunsparc} |
411 |
rm -rf %{buildroot}%{_bindir}/sunhostid |
412 |
cat << E-O-F > %{buildroot}%{_bindir}/sunhostid |
413 |
#!/bin/sh |
414 |
# this should be %{_bindir}/sunhostid or somesuch. |
415 |
# Copyright 1999 Peter Jones, <pjones@redhat.com> . |
416 |
# GPL and all that good stuff apply. |
417 |
( |
418 |
idprom=\`cat /proc/openprom/idprom\` |
419 |
echo \$idprom|dd bs=1 skip=2 count=2 |
420 |
echo \$idprom|dd bs=1 skip=27 count=6 |
421 |
echo |
422 |
) 2>/dev/null |
423 |
E-O-F |
424 |
chmod 755 %{buildroot}%{_bindir}/sunhostid |
425 |
%endif |
426 |
|
427 |
# PAM settings |
428 |
{ |
429 |
pushd %{buildroot}%{_sysconfdir}/pam.d |
430 |
install -m 644 %{SOURCE1} ./login |
431 |
install -m 644 %{SOURCE2} ./remote |
432 |
install -m 644 %{SOURCE3} ./chsh |
433 |
install -m 644 %{SOURCE3} ./chfn |
434 |
install -m 644 %{SOURCE5} ./su |
435 |
install -m 644 %{SOURCE6} ./su-l |
436 |
popd |
437 |
} |
438 |
|
439 |
%ifarch ppc |
440 |
cp -f ./clock-ppc %{buildroot}%{_sbindir}/clock-ppc |
441 |
mv %{buildroot}%{_sbindir}/hwclock %{buildroot}%{_sbindir}/clock-rs6k |
442 |
ln -sf clock-rs6k %{buildroot}%{_sbindir}/hwclock |
443 |
%endif |
444 |
ln -sf hwclock %{buildroot}%{_sbindir}/clock |
445 |
|
446 |
install -D -p -m 644 %{SOURCE10} %{buildroot}%{_tmpfilesdir}/uuidd.conf |
447 |
# And a dirs uuidd needs that the makefiles don't create |
448 |
install -d %{buildroot}/var/lib/libuuid |
449 |
|
450 |
# remove libtool junk (TODO) |
451 |
# (cg) When doing the usrmerge it turns out this file is still |
452 |
# packaged, so althought I corrected the path below, I had to comment it out |
453 |
# (it was apparently a no-op before) |
454 |
#rm -f %{buildroot}%{_libdir}/libblkid.la |
455 |
|
456 |
# remove stuff we don't want |
457 |
rm -f %{buildroot}%{_mandir}/man1/{line,newgrp,pg}.1* |
458 |
rm -f %{buildroot}%{_bindir}/{line,newgrp,pg} |
459 |
|
460 |
# remove static libs |
461 |
rm -f $RPM_BUILD_ROOT%{_libdir}/lib{uuid,blkid,mount}.a |
462 |
|
463 |
# Final cleanup |
464 |
%ifarch %no_hwclock_archs |
465 |
rm -f %{buildroot}%{_sbindir}/{hwclock,clock} %{buildroot}%{_mandir}/man8/hwclock.8* |
466 |
%endif |
467 |
%ifarch s390 s390x |
468 |
rm -f %{buildroot}{%{_bindir},%{_sbindir}}/{fdformat,tunelp,floppy} %{buildroot}%{_mandir}/man8/{fdformat,tunelp,floppy}.8* |
469 |
%endif |
470 |
|
471 |
# deprecated commands |
472 |
for I in %{_sbindir}/mkfs.bfs \ |
473 |
%{_bindir}/chkdupexe \ |
474 |
%{_bindir}/scriptreplay |
475 |
do |
476 |
rm -f %{buildroot}$I |
477 |
done |
478 |
|
479 |
# deprecated man pages |
480 |
for I in man1/chkdupexe.1 \ |
481 |
man8/mkfs.bfs.8 man1/scriptreplay.1; do |
482 |
rm -rf %{buildroot}%{_mandir}/${I}* |
483 |
done |
484 |
|
485 |
# we install getopt/getopt-*.{bash,tcsh} as doc files |
486 |
# note: versions <=2.12 use path "%{_datadir}/misc/getopt/*" |
487 |
chmod 644 misc-utils/getopt-*.{bash,tcsh} |
488 |
rm -f %{buildroot}%{_datadir}/getopt/* |
489 |
rmdir %{buildroot}%{_datadir}/getopt |
490 |
|
491 |
%if %{mtab_symlink} |
492 |
ln -s /proc/mounts %{buildroot}/etc/mtab |
493 |
%else |
494 |
touch %{buildroot}/etc/mtab |
495 |
%endif |
496 |
|
497 |
# /usr/sbin -> /usr/bin |
498 |
for I in raw; do |
499 |
if [ -e %{buildroot}%{_sbindir}/$I ]; then |
500 |
mv %{buildroot}%{_sbindir}/$I %{buildroot}%{_bindir}/$I |
501 |
fi |
502 |
done |
503 |
|
504 |
# remove vipw and vigr, they belong in shadow-utils |
505 |
rm -f %{buildroot}%{_sbindir}/{vipw,vigr} %{buildroot}%{_mandir}/man8/{vigr,vipw}.* |
506 |
|
507 |
%find_lang %{name} |
508 |
|
509 |
# the files section supports only one -f option... |
510 |
mv %{name}.lang %{name}.files |
511 |
|
512 |
# create list of setarch(8) symlinks |
513 |
find %{buildroot}%{_bindir}/ -regextype posix-egrep -type l \ |
514 |
-regex ".*(linux32|linux64|s390|s390x|i386|ppc|ppc64|ppc32|sparc|sparc64|sparc32|sparc32bash|mips|mips64|mips32|ia64|x86_64)$" \ |
515 |
-printf "%{_bindir}/%f\n" >> %{name}.files |
516 |
|
517 |
find %{buildroot}%{_mandir}/man8 -regextype posix-egrep \ |
518 |
-regex ".*(linux32|linux64|s390|s390x|i386|ppc|ppc64|ppc32|sparc|sparc64|sparc32|sparc32bash|mips|mips64|mips32|ia64|x86_64)\.8.*" \ |
519 |
-printf "%{_mandir}/man8/%f*\n" >> %{name}.files |
520 |
|
521 |
%post |
522 |
%ifarch ppc |
523 |
ISCHRP=`grep CHRP /proc/cpuinfo` |
524 |
if [ -z "$ISCHRP" ]; then |
525 |
ln -sf %{_sbindir}/clock-ppc %{_sbindir}/hwclock |
526 |
fi |
527 |
%endif |
528 |
|
529 |
%if %{mtab_symlink} |
530 |
rm -f /etc/mtab |
531 |
ln -s /proc/mounts /etc/mtab |
532 |
%else |
533 |
touch /etc/mtab |
534 |
/bin/chown root:root /etc/mtab |
535 |
/bin/chmod 0644 /etc/mtab |
536 |
%endif |
537 |
|
538 |
%post -n %{lib_blkid} |
539 |
[ -e /etc/blkid.tab ] && mv /etc/blkid.tab /etc/blkid/blkid.tab || : |
540 |
[ -e /etc/blkid.tab.old ] && mv /etc/blkid.tab.old /etc/blkid/blkid.tab.old || : |
541 |
|
542 |
%pre -n uuidd |
543 |
%_pre_useradd uuidd /var/lib/libuuid /bin/false |
544 |
|
545 |
%post -n uuidd |
546 |
%_tmpfilescreate uuidd |
547 |
%_post_service uuidd |
548 |
|
549 |
%preun -n uuidd |
550 |
%_preun_service uuidd |
551 |
|
552 |
%postun -n uuidd |
553 |
%_postun_userdel uuidd |
554 |
|
555 |
%files -f %{name}.files |
556 |
%defattr(-,root,root) |
557 |
%doc misc-utils/getopt-*.{bash,tcsh} |
558 |
%doc Documentation/releases/*-ReleaseNotes |
559 |
%{_bindir}/arch |
560 |
%{_bindir}/dmesg |
561 |
%attr(755,root,root) %{_bindir}/login |
562 |
%{_bindir}/lsblk |
563 |
%{_bindir}/more |
564 |
%{_bindir}/kill |
565 |
%{_bindir}/taskset |
566 |
%{_bindir}/ionice |
567 |
%{_bindir}/findmnt |
568 |
%{_bindir}/su |
569 |
%{_bindir}/wdctl |
570 |
%if %{include_raw} |
571 |
%{_bindir}/raw |
572 |
%{_udevrulesdir}/60-raw.rules |
573 |
%endif |
574 |
%config(noreplace) %{_sysconfdir}/pam.d/chfn |
575 |
%config(noreplace) %{_sysconfdir}/pam.d/chsh |
576 |
%config(noreplace) %{_sysconfdir}/pam.d/login |
577 |
%config(noreplace) %{_sysconfdir}/pam.d/remote |
578 |
%config(noreplace) %{_sysconfdir}/pam.d/su |
579 |
%config(noreplace) %{_sysconfdir}/pam.d/su-l |
580 |
%{_sbindir}/agetty |
581 |
%{_mandir}/man8/agetty.8* |
582 |
%{_sbindir}/blkid |
583 |
%{_sbindir}/blockdev |
584 |
%{_sbindir}/chcpu |
585 |
%{_sbindir}/fstrim |
586 |
%{_sbindir}/pivot_root |
587 |
%{_sbindir}/ctrlaltdel |
588 |
%{_sbindir}/addpart |
589 |
%{_sbindir}/delpart |
590 |
%{_sbindir}/partx |
591 |
%{_sbindir}/fsfreeze |
592 |
%{_sbindir}/swaplabel |
593 |
%{_mandir}/man8/partx.8* |
594 |
%{_mandir}/man8/addpart.8* |
595 |
%{_mandir}/man8/delpart.8* |
596 |
%{_mandir}/man8/findmnt.8* |
597 |
%{_mandir}/man8/fsfreeze.8* |
598 |
%{_mandir}/man8/fstrim.8* |
599 |
%{_mandir}/man8/lsblk.8* |
600 |
%{_mandir}/man8/swaplabel.8* |
601 |
%ifarch %ix86 alpha ia64 x86_64 s390 s390x ppc ppc64 %{sunsparc} %mips %arm |
602 |
%{_sbindir}/sfdisk |
603 |
%{_mandir}/man8/sfdisk.8* |
604 |
%{_sbindir}/cfdisk |
605 |
%{_mandir}/man8/cfdisk.8* |
606 |
%endif |
607 |
%{_sbindir}/fdisk |
608 |
%{_mandir}/man8/fdisk.8* |
609 |
%ifnarch %no_hwclock_archs |
610 |
%{_sbindir}/clock |
611 |
%{_sbindir}/hwclock |
612 |
%{_mandir}/man8/hwclock.8* |
613 |
%endif |
614 |
%ifarch ppc |
615 |
%{_sbindir}/clock-ppc |
616 |
%{_sbindir}/clock-rs6k |
617 |
%endif |
618 |
%{_sbindir}/findfs |
619 |
%{_sbindir}/fsck |
620 |
%{_sbindir}/mkfs |
621 |
%{_sbindir}/mkswap |
622 |
%{_sbindir}/nologin |
623 |
%{_sbindir}/sulogin |
624 |
%{_mandir}/man8/nologin.8* |
625 |
%{_bindir}/chrt |
626 |
%{_bindir}/cal |
627 |
%attr(4711,root,root) %{_bindir}/chfn |
628 |
%attr(4711,root,root) %{_bindir}/chsh |
629 |
%{_bindir}/col |
630 |
%{_bindir}/colcrt |
631 |
%{_bindir}/colrm |
632 |
%{_bindir}/column |
633 |
%ifarch %ix86 alpha ppc ppc64 %{sunsparc} x86_64 %mips %arm |
634 |
%{_bindir}/cytune |
635 |
%{_bindir}/prlimit |
636 |
%{_mandir}/man8/cytune.8* |
637 |
%endif |
638 |
%{_bindir}/ddate |
639 |
%{_bindir}/eject |
640 |
%ifnarch s390 s390x |
641 |
%{_sbindir}/fdformat |
642 |
%endif |
643 |
%{_bindir}/flock |
644 |
%{_bindir}/fallocate |
645 |
%{_bindir}/getopt |
646 |
%{_bindir}/hexdump |
647 |
%{_bindir}/ipcrm |
648 |
%{_bindir}/ipcs |
649 |
%{_bindir}/isosize |
650 |
%{_bindir}/logger |
651 |
%{_bindir}/look |
652 |
%{_bindir}/lslocks |
653 |
%{_bindir}/mcookie |
654 |
%{_bindir}/utmpdump |
655 |
%ifarch %ix86 alpha ia64 x86_64 s390 s390x ppc ppc64 %{sunsparc} %mips %arm |
656 |
%{_sbindir}/fsck.cramfs |
657 |
%{_sbindir}/mkfs.cramfs |
658 |
%endif |
659 |
%{_sbindir}/fsck.minix |
660 |
%{_sbindir}/mkfs.minix |
661 |
%{_bindir}/namei |
662 |
%{_bindir}/rename |
663 |
%{_bindir}/renice |
664 |
%{_bindir}/rev |
665 |
%{_bindir}/script |
666 |
%{_bindir}/setarch |
667 |
%{_bindir}/setsid |
668 |
%{_bindir}/setterm |
669 |
%ifarch %{sunsparc} |
670 |
%{_bindir}/sunhostid |
671 |
%endif |
672 |
%{_bindir}/tailf |
673 |
%{_bindir}/ul |
674 |
%{_bindir}/unshare |
675 |
%{_bindir}/uuidgen |
676 |
%{_bindir}/whereis |
677 |
%{_bindir}/ipcmk |
678 |
%{_bindir}/lscpu |
679 |
%attr(2755,root,tty) %{_bindir}/write |
680 |
|
681 |
%ghost %verify(not md5 size mtime) %config(noreplace,missingok) /etc/mtab |
682 |
|
683 |
%{_sbindir}/readprofile |
684 |
%ifnarch s390 s390x |
685 |
%{_sbindir}/tunelp |
686 |
%endif |
687 |
%{_sbindir}/rtcwake |
688 |
%{_sbindir}/ldattach |
689 |
%{_sbindir}/resizepart |
690 |
%{_mandir}/man1/arch.1* |
691 |
%{_mandir}/man1/cal.1* |
692 |
%{_mandir}/man1/chfn.1* |
693 |
%{_mandir}/man1/chsh.1* |
694 |
%{_mandir}/man1/col.1* |
695 |
%{_mandir}/man1/colcrt.1* |
696 |
%{_mandir}/man1/colrm.1* |
697 |
%{_mandir}/man1/column.1* |
698 |
%{_mandir}/man1/ddate.1* |
699 |
%{_mandir}/man1/eject.1* |
700 |
%{_mandir}/man1/flock.1* |
701 |
%{_mandir}/man1/fallocate.1* |
702 |
%{_mandir}/man1/getopt.1* |
703 |
%{_mandir}/man1/hexdump.1* |
704 |
%{_mandir}/man1/kill.1* |
705 |
%{_mandir}/man1/logger.1* |
706 |
%{_mandir}/man1/login.1* |
707 |
%{_mandir}/man1/look.1* |
708 |
%{_mandir}/man1/mcookie.1* |
709 |
%{_mandir}/man1/more.1* |
710 |
%{_mandir}/man1/namei.1* |
711 |
%{_mandir}/man1/prlimit.1* |
712 |
%{_mandir}/man1/rename.1* |
713 |
%{_mandir}/man1/rev.1* |
714 |
%{_mandir}/man1/script.1* |
715 |
%{_mandir}/man1/setterm.1* |
716 |
%{_mandir}/man1/su.1* |
717 |
%{_mandir}/man1/tailf.1* |
718 |
%{_mandir}/man1/ul.1* |
719 |
%{_mandir}/man1/uuidgen.1* |
720 |
%{_mandir}/man1/unshare.1* |
721 |
%{_mandir}/man1/utmpdump.1* |
722 |
%{_mandir}/man1/whereis.1* |
723 |
%{_mandir}/man1/write.1* |
724 |
%{_mandir}/man1/chrt.1* |
725 |
%{_mandir}/man1/ionice.1* |
726 |
%{_mandir}/man1/taskset.1* |
727 |
%{_mandir}/man1/renice.1* |
728 |
%{_mandir}/man1/ipcrm.1* |
729 |
%{_mandir}/man1/ipcs.1* |
730 |
%{_mandir}/man1/setsid.1* |
731 |
%{_mandir}/man1/dmesg.1* |
732 |
%{_mandir}/man1/ipcmk.1* |
733 |
%{_mandir}/man1/lscpu.1* |
734 |
%{_mandir}/man3/uuid_generate_time_safe.3* |
735 |
%{_mandir}/man8/blockdev.8* |
736 |
%{_mandir}/man8/blkid.8* |
737 |
%{_mandir}/man8/chcpu.8* |
738 |
%{_mandir}/man8/ctrlaltdel.8* |
739 |
%ifnarch s390 s390x |
740 |
%{_mandir}/man8/fdformat.8* |
741 |
%endif |
742 |
%{_mandir}/man8/findfs.8* |
743 |
%{_mandir}/man8/fsck.8* |
744 |
%{_mandir}/man8/isosize.8* |
745 |
%{_mandir}/man8/lslocks.8* |
746 |
%{_mandir}/man8/mkfs.8* |
747 |
%{_mandir}/man8/mkswap.8* |
748 |
%{_mandir}/man8/pivot_root.8* |
749 |
%{_mandir}/man8/readprofile.8* |
750 |
%if %{include_raw} |
751 |
%{_mandir}/man8/raw.8* |
752 |
%{_mandir}/man8/rawdevices.8* |
753 |
%endif |
754 |
%{_mandir}/man8/resizepart.8* |
755 |
%ifnarch s390 s390x |
756 |
%{_mandir}/man8/tunelp.8* |
757 |
%endif |
758 |
%{_mandir}/man8/setarch.8* |
759 |
%{_mandir}/man8/sulogin.8* |
760 |
%{_mandir}/man8/rtcwake.8* |
761 |
%{_mandir}/man8/ldattach.8* |
762 |
%{_mandir}/man8/wipefs.8* |
763 |
%{_mandir}/man8/wdctl.8* |
764 |
%{_mandir}/man8/fsck.minix.8* |
765 |
%{_mandir}/man8/mkfs.minix.8* |
766 |
%attr(4755,root,root) %{_bindir}/mount |
767 |
%attr(4755,root,root) %{_bindir}/umount |
768 |
%{_sbindir}/swapon |
769 |
%{_sbindir}/swapoff |
770 |
%{_sbindir}/switch_root |
771 |
%{_mandir}/man5/fstab.5* |
772 |
%{_mandir}/man8/mount.8* |
773 |
%{_mandir}/man8/swapoff.8* |
774 |
%{_mandir}/man8/swapon.8* |
775 |
%{_mandir}/man8/switch_root.8* |
776 |
%{_mandir}/man8/umount.8* |
777 |
%{_mandir}/man8/losetup.8* |
778 |
%lang(ru) %{_mandir}/ru/man1/ddate.1* |
779 |
%{_sbindir}/losetup |
780 |
%{_sbindir}/wipefs |
781 |
|
782 |
%files -n uuidd |
783 |
%defattr(-,root,root) |
784 |
%{_mandir}/man8/uuidd.8* |
785 |
%{_unitdir}/uuidd.* |
786 |
%{_tmpfilesdir}/uuidd.conf |
787 |
%attr(-, uuidd, uuidd) %{_sbindir}/uuidd |
788 |
%dir %attr(2775, uuidd, uuidd) /var/lib/libuuid |
789 |
|
790 |
%files -n %{lib_blkid} |
791 |
%defattr(-,root,root) |
792 |
%dir /etc/blkid |
793 |
%{_libdir}/libblkid.so.%{lib_blkid_major}* |
794 |
|
795 |
%files -n %{lib_blkid_devel} |
796 |
%defattr(-,root,root) |
797 |
%if %{with uclibc} |
798 |
%{uclibc_root}%{_libdir}/libblkid.a |
799 |
%endif |
800 |
%{_libdir}/libblkid.la |
801 |
%{_libdir}/libblkid.so |
802 |
%{_includedir}/blkid |
803 |
%{_mandir}/man3/libblkid.3* |
804 |
%{_libdir}/pkgconfig/blkid.pc |
805 |
|
806 |
%files -n %{lib_uuid} |
807 |
%defattr(-,root,root) |
808 |
%{_libdir}/libuuid.so.%{lib_uuid_major}* |
809 |
|
810 |
%files -n %{lib_uuid_devel} |
811 |
%defattr(-,root,root) |
812 |
%doc NEWS AUTHORS |
813 |
%if %{with uclibc} |
814 |
%{uclibc_root}%{_libdir}/libuuid.a |
815 |
%endif |
816 |
%{_libdir}/libuuid.la |
817 |
%{_libdir}/libuuid.so |
818 |
%{_includedir}/uuid |
819 |
%{_mandir}/man3/uuid.3* |
820 |
%{_mandir}/man3/uuid_clear.3* |
821 |
%{_mandir}/man3/uuid_compare.3* |
822 |
%{_mandir}/man3/uuid_copy.3* |
823 |
%{_mandir}/man3/uuid_generate.3* |
824 |
%{_mandir}/man3/uuid_generate_random.3* |
825 |
%{_mandir}/man3/uuid_generate_time.3* |
826 |
%{_mandir}/man3/uuid_is_null.3* |
827 |
%{_mandir}/man3/uuid_parse.3* |
828 |
%{_mandir}/man3/uuid_time.3* |
829 |
%{_mandir}/man3/uuid_unparse.3* |
830 |
%{_libdir}/pkgconfig/uuid.pc |
831 |
|
832 |
%files -n %{lib_mount} |
833 |
%defattr(-,root,root) |
834 |
%{_libdir}/libmount.so.%{lib_mount_major}* |
835 |
|
836 |
%files -n %{lib_mount_devel} |
837 |
%defattr(-,root,root) |
838 |
%{_includedir}/libmount |
839 |
%{_libdir}/libmount.so |
840 |
%{_libdir}/libmount.la |
841 |
%{_libdir}/pkgconfig/mount.pc |
842 |
|