blob: b188b751f32e4f9d6437bc8e12a512141c4603ae [file] [log] [blame]
Theodore Ts'od606c302003-03-16 20:40:36 -05001%define _root_sbindir /sbin
2%define _root_libdir /%{_lib}
Theodore Ts'o36569f82004-05-04 22:17:27 -04003%define _root_localedir /usr/share/locale
Andreas Dilger927566a2006-11-12 19:41:25 -05004%define _root_etcdir /etc
Theodore Ts'od606c302003-03-16 20:40:36 -05005
Theodore Ts'oe2193cf2009-07-11 16:22:51 -04006Summary: Utilities for managing ext2/ext3/ext4 filesystems
Theodore Ts'o24757fa1997-04-29 17:39:27 +00007Name: e2fsprogs
Andreas Dilger927566a2006-11-12 19:41:25 -05008Version: @E2FSPROGS_PKGVER@
Theodore Ts'o24757fa1997-04-29 17:39:27 +00009Release: 0
Theodore Ts'of6c9b0e2006-09-12 01:43:42 -040010License: GPLv2
Theodore Ts'o8a31ffe1999-10-23 03:33:15 +000011Group: System Environment/Base
Theodore Ts'od606c302003-03-16 20:40:36 -050012Source: ftp://download.sourceforge.net/pub/sourceforge/e2fsprogs/e2fsprogs-%{version}.tar.gz
13Url: http://e2fsprogs.sourceforge.net/
Theodore Ts'of9e67062000-07-13 23:25:54 +000014Prereq: /sbin/ldconfig
Theodore Ts'od606c302003-03-16 20:40:36 -050015BuildRoot: %{_tmppath}/%{name}-root
Theodore Ts'o24757fa1997-04-29 17:39:27 +000016
17%description
Theodore Ts'o8a31ffe1999-10-23 03:33:15 +000018The e2fsprogs package contains a number of utilities for creating,
Theodore Ts'oe2193cf2009-07-11 16:22:51 -040019checking, modifying, and correcting any inconsistencies in ext2, ext3,
20and ext4 filesystems. E2fsprogs contains e2fsck (used to repair
21filesystem inconsistencies after an unclean shutdown), mke2fs (used to
22initialize a partition to contain an empty ext2 filesystem), debugfs
23(used to examine the internal structure of a filesystem, to manually
24repair a corrupted filesystem or to create test cases for e2fsck),
25tune2fs (used to modify filesystem parameters), resize2fs to grow and
26shrink unmounted ext2 filesystems, and most of the other core ext2fs
27filesystem utilities.
Theodore Ts'o8a31ffe1999-10-23 03:33:15 +000028
Theodore Ts'oe2193cf2009-07-11 16:22:51 -040029You should install the e2fsprogs package if you are using any ext2,
30ext3, or ext4 filesystems (if you're not sure, you probably should
31install this package). You may also need to install it (even if you
32don't use ext2/ext3/ext4) for the libuuid and libblkid libraries and
33fsck tool that are included here.
Theodore Ts'o24757fa1997-04-29 17:39:27 +000034
35%package devel
Theodore Ts'o8a31ffe1999-10-23 03:33:15 +000036Summary: Ext2 filesystem-specific static libraries and headers.
Theodore Ts'o24757fa1997-04-29 17:39:27 +000037Group: Development/Libraries
Theodore Ts'od606c302003-03-16 20:40:36 -050038Requires: e2fsprogs = %{version}
39Prereq: /sbin/install-info
Theodore Ts'o24757fa1997-04-29 17:39:27 +000040
Theodore Ts'of9e67062000-07-13 23:25:54 +000041%description devel
Theodore Ts'o8a31ffe1999-10-23 03:33:15 +000042E2fsprogs-devel contains the libraries and header files needed to
Theodore Ts'oe2193cf2009-07-11 16:22:51 -040043develop ext2, ext3, or ext4 filesystem-specific programs.
Theodore Ts'o8a31ffe1999-10-23 03:33:15 +000044
Theodore Ts'oe2193cf2009-07-11 16:22:51 -040045You should install e2fsprogs-devel if you want to develop
46ext2. ext3. or ext4 filesystem-specific programs. If you install
47e2fsprogs-devel, you'll also want to install e2fsprogs.
Theodore Ts'o24757fa1997-04-29 17:39:27 +000048
Eric Sandeenf8897f42008-01-19 18:13:32 -050049%package -n uuidd
50Summary: helper daemon to guarantee uniqueness of time-based UUIDs
51Group: System Environment/Daemons
52License: GPLv2
53Requires: e2fsprogs = %{version}
54Requires(pre): shadow-utils
55
56%description -n uuidd
57The uuidd package contains a userspace daemon (uuidd) which guarantees
58uniqueness of time-based UUID generation even at very high rates on
59SMP systems.
60
Theodore Ts'o24757fa1997-04-29 17:39:27 +000061%prep
62%setup
63
Theodore Ts'od606c302003-03-16 20:40:36 -050064%build
Andreas Dilger28b74da2008-08-24 21:03:17 -040065%configure --enable-elf-shlibs --enable-nls \
66 %{?extra_config_flags:%extra_config_flags}
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -050067make
Theodore Ts'oc5ca71d2007-08-03 20:12:32 -040068make check
Theodore Ts'o24757fa1997-04-29 17:39:27 +000069
70%install
Theodore Ts'of9e67062000-07-13 23:25:54 +000071rm -rf $RPM_BUILD_ROOT
Theodore Ts'o24757fa1997-04-29 17:39:27 +000072export PATH=/sbin:$PATH
Theodore Ts'od606c302003-03-16 20:40:36 -050073make install install-libs DESTDIR="$RPM_BUILD_ROOT" \
74 root_sbindir=%{_root_sbindir} root_libdir=%{_root_libdir}
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -050075/sbin/ldconfig -n ${RPM_BUILD_ROOT}%{_libdir}
Eric Sandeenf8897f42008-01-19 18:13:32 -050076
77# Add a dir that uuidd needs that the Makefiles don't create
78install -d $RPM_BUILD_ROOT/var/lib/libuuid
79
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -050080%find_lang %{name}
Theodore Ts'o24757fa1997-04-29 17:39:27 +000081
Theodore Ts'o24757fa1997-04-29 17:39:27 +000082%clean
83rm -rf $RPM_BUILD_ROOT
84
Theodore Ts'od606c302003-03-16 20:40:36 -050085%post -p /sbin/ldconfig
Theodore Ts'o24757fa1997-04-29 17:39:27 +000086
Theodore Ts'of9e67062000-07-13 23:25:54 +000087%postun -p /sbin/ldconfig
88
89%post devel
Theodore Ts'od606c302003-03-16 20:40:36 -050090if [ -x /sbin/install-info -a -f %{_infodir}/libext2fs.info.gz ]; then
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -050091 /sbin/install-info %{_infodir}/libext2fs.info.gz %{_infodir}/dir
Theodore Ts'of9e67062000-07-13 23:25:54 +000092fi
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -050093exit 0
Theodore Ts'of9e67062000-07-13 23:25:54 +000094
95%postun devel
Theodore Ts'od606c302003-03-16 20:40:36 -050096if [ $1 = 0 -a -x /sbin/install-info -a -f %{_infodir}/libext2fs.info.gz ]; then
Theodore Ts'of5955dd2000-10-25 02:38:39 +000097 /sbin/install-info --delete %{_infodir}/libext2fs.info.gz %{_infodir}/dir
Theodore Ts'of9e67062000-07-13 23:25:54 +000098fi
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -050099exit 0
Theodore Ts'o24757fa1997-04-29 17:39:27 +0000100
Eric Sandeenf8897f42008-01-19 18:13:32 -0500101%pre -n uuidd
102getent group uuidd >/dev/null || groupadd -r uuidd
103getent passwd uuidd >/dev/null || \
104useradd -r -g uuidd -d /var/lib/libuuid -s /sbin/nologin \
105 -c "UUID generator helper daemon" uuidd
106exit 0
107
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500108%files -f %{name}.lang
Theodore Ts'of9e67062000-07-13 23:25:54 +0000109%defattr(-,root,root)
110%doc README RELEASE-NOTES
Theodore Ts'o24757fa1997-04-29 17:39:27 +0000111
Theodore Ts'od606c302003-03-16 20:40:36 -0500112%{_root_sbindir}/badblocks
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500113%{_root_sbindir}/blkid
Theodore Ts'od606c302003-03-16 20:40:36 -0500114%{_root_sbindir}/debugfs
115%{_root_sbindir}/dumpe2fs
116%{_root_sbindir}/e2fsck
117%{_root_sbindir}/e2image
118%{_root_sbindir}/e2label
Eric Sandeen9ea7b792008-06-18 16:16:35 -0500119%{_root_sbindir}/e2undo
Theodore Ts'od606c302003-03-16 20:40:36 -0500120%{_root_sbindir}/findfs
121%{_root_sbindir}/fsck
122%{_root_sbindir}/fsck.ext2
123%{_root_sbindir}/fsck.ext3
Theodore Ts'oeda08d42008-05-14 18:23:47 -0400124%{_root_sbindir}/fsck.ext4
125%{_root_sbindir}/fsck.ext4dev
Theodore Ts'of9ddad52003-04-14 18:05:12 -0400126%{_root_sbindir}/logsave
Theodore Ts'od606c302003-03-16 20:40:36 -0500127%{_root_sbindir}/mke2fs
Andreas Dilger927566a2006-11-12 19:41:25 -0500128%{_root_etcdir}/mke2fs.conf
Theodore Ts'od606c302003-03-16 20:40:36 -0500129%{_root_sbindir}/mkfs.ext2
130%{_root_sbindir}/mkfs.ext3
Theodore Ts'oeda08d42008-05-14 18:23:47 -0400131%{_root_sbindir}/mkfs.ext4
132%{_root_sbindir}/mkfs.ext4dev
Theodore Ts'od606c302003-03-16 20:40:36 -0500133%{_root_sbindir}/resize2fs
134%{_root_sbindir}/tune2fs
Theodore Ts'o477b2352003-12-25 14:31:08 -0500135%{_sbindir}/filefrag
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500136%{_sbindir}/mklost+found
Theodore Ts'o0b2681f2009-07-22 03:40:58 -0400137%{_sbindir}/e2freefrag
Theodore Ts'o24757fa1997-04-29 17:39:27 +0000138
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500139%{_root_libdir}/libblkid.so.*
Theodore Ts'od606c302003-03-16 20:40:36 -0500140%{_root_libdir}/libcom_err.so.*
141%{_root_libdir}/libe2p.so.*
142%{_root_libdir}/libext2fs.so.*
143%{_root_libdir}/libss.so.*
Theodore Ts'od606c302003-03-16 20:40:36 -0500144%{_root_libdir}/libuuid.so.*
Theodore Ts'of9e67062000-07-13 23:25:54 +0000145
Theodore Ts'o6ea8d0f2004-09-24 12:15:14 -0400146%{_libdir}/e2initrd_helper
147
Theodore Ts'od606c302003-03-16 20:40:36 -0500148%{_bindir}/chattr
149%{_bindir}/lsattr
150%{_bindir}/uuidgen
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000151%{_mandir}/man1/chattr.1*
152%{_mandir}/man1/lsattr.1*
153%{_mandir}/man1/uuidgen.1*
Theodore Ts'of9e67062000-07-13 23:25:54 +0000154
Andreas Dilger927566a2006-11-12 19:41:25 -0500155%{_mandir}/man5/e2fsck.conf.5*
156%{_mandir}/man5/mke2fs.conf.5*
157
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000158%{_mandir}/man8/badblocks.8*
Theodore Ts'od606c302003-03-16 20:40:36 -0500159%{_mandir}/man8/blkid.8*
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000160%{_mandir}/man8/debugfs.8*
161%{_mandir}/man8/dumpe2fs.8*
162%{_mandir}/man8/e2fsck.8*
Theodore Ts'od606c302003-03-16 20:40:36 -0500163%{_mandir}/man8/findfs.8*
164%{_mandir}/man8/fsck.ext2.8*
165%{_mandir}/man8/fsck.ext3.8*
Theodore Ts'oeda08d42008-05-14 18:23:47 -0400166%{_mandir}/man8/fsck.ext4.8*
167%{_mandir}/man8/fsck.ext4dev.8*
Theodore Ts'od5d92152001-05-11 06:19:33 +0000168%{_mandir}/man8/e2image.8*
Theodore Ts'od606c302003-03-16 20:40:36 -0500169%{_mandir}/man8/e2label.8*
Eric Sandeen9ea7b792008-06-18 16:16:35 -0500170%{_mandir}/man8/e2undo.8*
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000171%{_mandir}/man8/fsck.8*
Theodore Ts'of9ddad52003-04-14 18:05:12 -0400172%{_mandir}/man8/logsave.8*
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000173%{_mandir}/man8/mke2fs.8*
Theodore Ts'od606c302003-03-16 20:40:36 -0500174%{_mandir}/man8/mkfs.ext2.8*
175%{_mandir}/man8/mkfs.ext3.8*
Theodore Ts'oeda08d42008-05-14 18:23:47 -0400176%{_mandir}/man8/mkfs.ext4.8*
177%{_mandir}/man8/mkfs.ext4dev.8*
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000178%{_mandir}/man8/mklost+found.8*
179%{_mandir}/man8/resize2fs.8*
180%{_mandir}/man8/tune2fs.8*
Theodore Ts'o477b2352003-12-25 14:31:08 -0500181%{_mandir}/man8/filefrag.8*
Theodore Ts'o0b2681f2009-07-22 03:40:58 -0400182%{_mandir}/man8/e2freefrag.8*
Theodore Ts'o24757fa1997-04-29 17:39:27 +0000183
184%files devel
Theodore Ts'of9e67062000-07-13 23:25:54 +0000185%defattr(-,root,root)
Theodore Ts'of5955dd2000-10-25 02:38:39 +0000186%{_infodir}/libext2fs.info*
Theodore Ts'od606c302003-03-16 20:40:36 -0500187%{_bindir}/compile_et
188%{_bindir}/mk_cmds
Theodore Ts'of9e67062000-07-13 23:25:54 +0000189
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500190%{_libdir}/libblkid.a
191%{_libdir}/libblkid.so
Theodore Ts'od606c302003-03-16 20:40:36 -0500192%{_libdir}/libcom_err.a
193%{_libdir}/libcom_err.so
194%{_libdir}/libe2p.a
195%{_libdir}/libe2p.so
196%{_libdir}/libext2fs.a
197%{_libdir}/libext2fs.so
198%{_libdir}/libss.a
199%{_libdir}/libss.so
Theodore Ts'od606c302003-03-16 20:40:36 -0500200%{_libdir}/libuuid.a
201%{_libdir}/libuuid.so
Theodore Ts'of9e67062000-07-13 23:25:54 +0000202
Theodore Ts'oe6441862005-01-26 12:59:25 -0500203%{_libdir}/pkgconfig/blkid.pc
204%{_libdir}/pkgconfig/com_err.pc
205%{_libdir}/pkgconfig/e2p.pc
206%{_libdir}/pkgconfig/ext2fs.pc
207%{_libdir}/pkgconfig/ss.pc
208%{_libdir}/pkgconfig/uuid.pc
209
Theodore Ts'od606c302003-03-16 20:40:36 -0500210%{_datadir}/et
211%{_datadir}/ss
212%{_includedir}/blkid
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500213%{_includedir}/e2p
Theodore Ts'od606c302003-03-16 20:40:36 -0500214%{_includedir}/et
Andreas Dilgercf5301d2011-06-11 10:58:25 -0400215%{_includedir}/com_err.h
Theodore Ts'od606c302003-03-16 20:40:36 -0500216%{_includedir}/ext2fs
217%{_includedir}/ss
218%{_includedir}/uuid
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000219%{_mandir}/man1/compile_et.1*
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500220%{_mandir}/man1/mk_cmds.1*
Theodore Ts'o16c1ce82000-10-25 14:59:13 +0000221%{_mandir}/man3/com_err.3*
Theodore Ts'od606c302003-03-16 20:40:36 -0500222%{_mandir}/man3/libblkid.3*
Theodore Ts'o6d493492004-05-04 22:05:05 -0400223%{_mandir}/man3/uuid.3*
Theodore Ts'ocf1b23e2004-03-04 21:05:14 -0500224%{_mandir}/man3/uuid_clear.3*
225%{_mandir}/man3/uuid_compare.3*
226%{_mandir}/man3/uuid_copy.3*
227%{_mandir}/man3/uuid_generate.3*
228%{_mandir}/man3/uuid_generate_random.3*
229%{_mandir}/man3/uuid_generate_time.3*
230%{_mandir}/man3/uuid_is_null.3*
231%{_mandir}/man3/uuid_parse.3*
232%{_mandir}/man3/uuid_time.3*
233%{_mandir}/man3/uuid_unparse.3*
234
Eric Sandeenf8897f42008-01-19 18:13:32 -0500235%files -n uuidd
236%defattr(-,root,root)
237# if you want to run via init
238# /etc/init.d/uuidd
239%{_mandir}/man8/uuidd.8*
240%attr(6755, uuidd, uuidd) %{_sbindir}/uuidd
241%dir %attr(2775, uuidd, uuidd) /var/lib/libuuid
242