Make hostonly check for dmraid only pass if root is really on
[dracut.git] / dracut.spec
blobf6a0a47ca54a42ddad86ee9a43b0e0b909048b2c
1 %if 0%{?fedora} < 12
2 %define with_switch_root 1
3 %else
4 %define with_switch_root 0
5 %endif
7 %if %{defined gittag}
8 %define rdist 1.git%{gittag}%{?dist}
9 %define dashgittag -%{gittag}
10 %else
11 %define rdist %{?dist}
12 %endif
14 Name: dracut
15 Version: 0.9
16 Release: 1%{?rdist}
17 Summary: Initramfs generator using udev
18 Group: System Environment/Base
19 License: GPLv2+
20 URL: http://apps.sourceforge.net/trac/dracut/wiki
21 Source0: dracut-%{version}%{?dashgittag}.tar.bz2
22 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
23 Requires: udev
24 Requires: util-linux-ng
25 Requires: module-init-tools >= 3.7-9
26 Requires: cpio
27 Requires: coreutils
28 Requires: findutils
29 Requires: binutils
30 Requires: grep
31 Requires: which
32 Requires: mktemp >= 1.5-5
33 Requires: mount
34 Requires: bash
35 Requires: dash
36 Requires: /bin/sh
37 Requires: fileutils, gzip, tar
38 Requires: lvm2 >= 2.02.33-9, dhclient
39 Requires: filesystem >= 2.1.0, cpio, device-mapper, initscripts >= 8.63-1
40 Requires: e2fsprogs >= 1.38-12, libselinux, libsepol, coreutils
41 Requires: mdadm, elfutils-libelf, plymouth >= 0.7.0
42 Requires: cryptsetup-luks
43 Requires: bridge-utils
44 Requires: file
45 Requires: bzip2
46 %ifnarch s390 s390x
47 Requires: dmraid
48 Requires: kbd
49 %endif
51 %if ! 0%{?with_switch_root}
52 Requires: util-linux-ng >= 2.16
53 BuildArch: noarch
54 %endif
56 %description
57 dracut is a new, event-driven initramfs infrastructure based around udev.
59 %package generic
60 Summary: Metapackage to build a generic initramfs with dracut
61 Requires: %{name} = %{version}-%{release}
62 Requires: rpcbind nfs-utils
63 Requires: iscsi-initiator-utils
64 Requires: nbd
65 Requires: net-tools iproute
66 Requires: plymouth-system-theme plymouth-theme-charge plymouth-theme-solar
67 Requires: plymouth-theme-fade-in plymouth-theme-spinfinity
69 %description generic
70 This package requires everything which is needed to build a generic
71 all purpose initramfs with dracut.
73 %package kernel
74 Summary: Metapackage to build generic initramfs with dracut with only kernel modules
75 Requires: %{name} = %{version}-%{release}
76 Requires: ql2100-firmware
77 Requires: ql2200-firmware
78 Requires: ql23xx-firmware
79 Requires: ql2400-firmware
80 Requires: ql2500-firmware
82 %description kernel
83 This package requires everything which is needed to build a initramfs with all
84 kernel modules and firmware files needed by dracut modules.
86 %package tools
87 Summary: dracut tools to build the local initramfs
88 Requires: coreutils cryptsetup-luks device-mapper
89 Requires: diffutils dmraid findutils gawk grep lvm2
90 Requires: module-init-tools sed
91 Requires: cpio gzip
93 %description tools
94 This package contains tools to assemble the local initrd and host configuration.
96 %prep
97 %setup -q -n %{name}-%{version}%{?dashgittag}
99 %build
100 make
103 %install
104 rm -rf $RPM_BUILD_ROOT
105 make install DESTDIR=$RPM_BUILD_ROOT sbindir=/sbin sysconfdir=/etc mandir=%{_mandir}
107 %if ! 0%{?with_switch_root}
108 rm -f $RPM_BUILD_ROOT/sbin/switch_root
109 %endif
111 mkdir -p $RPM_BUILD_ROOT/boot/dracut
112 mkdir -p $RPM_BUILD_ROOT/var/lib/dracut/overlay
114 %clean
115 rm -rf $RPM_BUILD_ROOT
117 %files
118 %defattr(-,root,root,0755)
119 %doc README HACKING TODO COPYING AUTHORS NEWS
120 /sbin/dracut
121 %if 0%{?with_switch_root}
122 /sbin/switch_root
123 %endif
124 %dir %{_datadir}/dracut
125 %{_datadir}/dracut/dracut-functions
126 %{_datadir}/dracut/modules.d
127 %config(noreplace) /etc/dracut.conf
128 %{_mandir}/man8/dracut.8*
130 %files generic
131 %defattr(-,root,root,0755)
132 %doc README.generic
134 %files kernel
135 %defattr(-,root,root,0755)
136 %doc README.kernel
138 %files tools
139 %defattr(-,root,root,0755)
140 %doc COPYING NEWS
141 /sbin/dracut-gencmdline
142 /sbin/dracut-catimages
143 %dir /boot/dracut
144 %dir /var/lib/dracut
145 %dir /var/lib/dracut/overlay
147 %changelog
148 * Fri Aug 14 2009 Harald Hoyer <harald@redhat.com> 0.9-1
149 - version 0.9
150 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
152 * Thu Aug 06 2009 Harald Hoyer <harald@redhat.com> 0.8-1
153 - version 0.8
154 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
156 * Fri Jul 24 2009 Harald Hoyer <harald@redhat.com> 0.7-1
157 - version 0.7
158 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
160 * Wed Jul 22 2009 Harald Hoyer <harald@redhat.com> 0.6-1
161 - version 0.6
162 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
164 * Fri Jul 17 2009 Harald Hoyer <harald@redhat.com> 0.5-1
165 - version 0.5
166 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
168 * Sat Jul 04 2009 Harald Hoyer <harald@redhat.com> 0.4-1
169 - version 0.4
170 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
172 * Thu Jul 02 2009 Harald Hoyer <harald@redhat.com> 0.3-1
173 - version 0.3
174 - see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
176 * Wed Jul 01 2009 Harald Hoyer <harald@redhat.com> 0.2-1
177 - version 0.2
179 * Fri Jun 19 2009 Harald Hoyer <harald@redhat.com> 0.1-1
180 - first release
182 * Thu Dec 18 2008 Jeremy Katz <katzj@redhat.com> - 0.0-1
183 - Initial build