1 Summary: A collection of basic system utilities
5 License: GPLv2 and GPLv2+ and BSD with advertising and Public Domain
7 URL: ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng
8 Source0: ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng/v2.16/util-linux-ng-%{version}.tar.gz
10 #BuildRequires: e2fsprogs-devel >= 1.36
11 BuildRequires: ncurses-devel
12 BuildRequires: zlib-devel
13 BuildRequires: popt-devel
14 Provides: util-linux = %{version}
18 The util-linux-ng package contains a large variety of low-level system
19 utilities that are necessary for a Linux system to function. Among
20 others, Util-linux contains the fdisk configuration tool and the login
24 Summary: Block device ID library
25 Group: System/Libraries
28 %description -n libblkid
29 This is block device identification library, part of util-linux-ng.
31 %package -n libblkid-devel
32 Summary: Block device ID library
33 Group: Development/Libraries
35 Requires: libblkid = %{version}-%{release}
37 %description -n libblkid-devel
38 This is the block device identification development library and headers,
39 part of util-linux-ng.
42 Summary: Universally unique ID library
43 Group: System/Libraries
46 %description -n libuuid
47 This is the universally unique ID library, part of e2fsprogs.
49 The libuuid library generates and parses 128-bit universally unique
50 id's (UUID's). A UUID is an identifier that is unique across both
51 space and time, with respect to the space of all UUIDs. A UUID can
52 be used for multiple purposes, from tagging objects with an extremely
53 short lifetime, to reliably identifying very persistent objects
56 See also the "uuid" package, which is a separate implementation.
58 %package -n libuuid-devel
59 Summary: Universally unique ID library
60 Group: Development/Libraries
62 Requires: libuuid = %{version}-%{release}
64 %description -n libuuid-devel
65 This is the universally unique ID development library and headers,
68 The libuuid library generates and parses 128-bit universally unique
69 id's (UUID's). A UUID is an identifier that is unique across both
70 space and time, with respect to the space of all UUIDs. A UUID can
71 be used for multiple purposes, from tagging objects with an extremely
72 short lifetime, to reliably identifying very persistent objects
75 See also the "uuid-devel" package, which is a separate implementation.
79 Summary: Helper daemon to guarantee uniqueness of time-based UUIDs
81 Requires: libuuid = %{version}-%{release}
85 The uuidd package contains a userspace daemon (uuidd) which guarantees
86 uniqueness of time-based UUID generation even at very high rates on
95 export CFLAGS="-D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 $RPM_OPT_FLAGS"
96 export SUID_CFLAGS="-fpie"
97 export SUID_LDFLAGS="-pie"
103 --with-fsprobe=builtin \
104 --disable-makeinstall-chown \
115 rm -rf ${RPM_BUILD_ROOT}
119 # And a dirs uuidd needs that the makefiles don't create
120 install -d ${RPM_BUILD_ROOT}/var/run/uuidd
121 install -d ${RPM_BUILD_ROOT}/var/lib/libuuid
124 # remove libtool junk
125 rm -f ${RPM_BUILD_ROOT}/usr/lib/libblkid.la
127 # deprecated commands
128 for I in /sbin/fsck.minix /sbin/fsck /sbin/mkfs.{bfs,minix} /sbin/sln \
129 /usr/bin/chkdupexe %{_bindir}/line %{_bindir}/pg %{_bindir}/newgrp \
130 /sbin/shutdown %{_bindir}/scriptreplay /usr/sbin/vipw /usr/sbin/vigr; do
131 rm -f $RPM_BUILD_ROOT$I
134 # deprecated man pages
135 for I in man1/chkdupexe.1 man1/line.1 man1/pg.1 man1/newgrp.1 \
136 man8/fsck.minix.8 man8/fsck.8 man8/mkfs.minix.8 man8/mkfs.bfs.8 man1/scriptreplay.1 \
137 man8/vipw.8 man8/vigr; do
138 rm -rf $RPM_BUILD_ROOT%{_mandir}/${I}*
142 ln -sf ../../bin/kill $RPM_BUILD_ROOT%{_bindir}/kill
146 # create list of setarch(8) symlinks
147 find $RPM_BUILD_ROOT%{_bindir}/ -regextype posix-egrep -type l \
148 -regex ".*(linux32|linux64|s390|s390x|i386|ppc|ppc64|ppc32|sparc|sparc64|sparc32|sparc32bash|mips|mips64|mips32|ia64|x86_64)$" \
149 -printf "%{_bindir}/%f\n" >> %{name}.files
151 find $RPM_BUILD_ROOT%{_mandir}/man8 -regextype posix-egrep \
152 -regex ".*(linux32|linux64|s390|s390x|i386|ppc|ppc64|ppc32|sparc|sparc64|sparc32|sparc32bash|mips|mips64|mips32|ia64|x86_64)\.8.*" \
153 -printf "%{_mandir}/man8/%f*\n" >> %{name}.files
155 rm -f $RPM_BUILD_ROOT/usr/share/info/dir
159 # only for minimal buildroots without /var/log
160 [ -d /var/log ] || /bin/mkdir -p /var/log
161 /bin/touch /var/log/lastlog
162 /bin/chown root:root /var/log/lastlog
163 /bin/chmod 0644 /var/log/lastlog
169 [ -e /etc/blkid.tab ] && mv /etc/blkid.tab /etc/blkid/blkid.tab || :
170 [ -e /etc/blkid.tab.old ] && mv /etc/blkid.tab.old /etc/blkid/blkid.tab.old || :
172 %postun -n libblkid -p /sbin/ldconfig
174 %post -n libuuid -p /sbin/ldconfig
175 %postun -n libuuid -p /sbin/ldconfig
178 #getent group uuidd >/dev/null || groupadd -r uuidd
179 #getent passwd uuidd >/dev/null || \
180 #useradd -r -g uuidd -d /var/lib/libuuid -s /sbin/nologin \
181 # -c "UUID generator helper daemon" uuidd
185 [ -e /sbin/chkconfig ] && /sbin/chkconfig --add uuidd
188 if [ "$1" = 0 ]; then
189 [ -e /sbin/service ] && /sbin/service uuidd stop > /dev/null 2>&1 || :
190 [ -e /sbin/chkconfig ] && /sbin/chkconfig --del uuidd
196 %files -f util-linux-ng.files
197 %defattr(-,root,root)
198 %ghost %attr(0644,root,root) %verify(not md5 size mtime) /var/log/lastlog
200 %attr(4755,root,root) /bin/mount
201 %attr(4755,root,root) /bin/umount
252 %attr(2755,root,tty) /usr/bin/write
255 /usr/sbin/readprofile
258 /usr/share/getopt/getopt-parse.bash
259 %exclude /usr/share/getopt/getopt-parse.tcsh
260 /usr/share/getopt/getopt-test.bash
261 %exclude /usr/share/getopt/getopt-test.tcsh
264 %defattr(-,root,root)
265 #/etc/rc.d/init.d/uuidd
266 %attr(-, uuidd, uuidd) %{_sbindir}/uuidd
267 %dir %attr(2775, uuidd, uuidd) /var/lib/libuuid
268 %dir %attr(2775, uuidd, uuidd) /var/run/uuidd
271 %defattr(-,root,root)
272 /%{_libdir}/libblkid.so.*
274 %files -n libblkid-devel
275 %defattr(-,root,root)
276 %{_libdir}/libblkid.so
278 %{_libdir}/pkgconfig/blkid.pc
281 %defattr(-,root,root)
282 /usr/lib/libuuid.so.*
284 %files -n libuuid-devel
285 %defattr(-,root,root)
286 %{_libdir}/libuuid.so
288 %{_libdir}/pkgconfig/uuid.pc