summaryrefslogtreecommitdiff
path: root/dracut.spec
diff options
context:
space:
mode:
authorHarald Hoyer <harald@redhat.com>2013-03-11 15:59:13 +0100
committerHarald Hoyer <harald@redhat.com>2013-03-11 18:58:32 +0100
commit2fa6fd3aaa3015ad80b2b16f68c9b6de6724f202 (patch)
tree743f2da11700bd8a68cd1875958620352f883ecf /dracut.spec
parentdd5875499ece9dbc90e10eafd0073ee15d0c86a4 (diff)
downloaddracut-2fa6fd3aaa3015ad80b2b16f68c9b6de6724f202.tar.gz
dracut-2fa6fd3aaa3015ad80b2b16f68c9b6de6724f202.tar.bz2
dracut-2fa6fd3aaa3015ad80b2b16f68c9b6de6724f202.zip
add 51-dracut-rescue-postinst.sh
also fixup 51-dracut-rescue.install to read in dracut conf
Diffstat (limited to 'dracut.spec')
-rw-r--r--dracut.spec18
1 files changed, 13 insertions, 5 deletions
diff --git a/dracut.spec b/dracut.spec
index 14ce0d01..940d3642 100644
--- a/dracut.spec
+++ b/dracut.spec
@@ -84,6 +84,7 @@ Requires: file
Requires: kpartx
Requires: udev > 166
Requires: kbd kbd-misc
+
%if 0%{?fedora} || 0%{?rhel} > 6
Requires: util-linux >= 2.21
Conflicts: systemd < 198
@@ -234,8 +235,14 @@ rm $RPM_BUILD_ROOT%{_bindir}/mkinitrd
rm $RPM_BUILD_ROOT%{_bindir}/lsinitrd
%endif
-mkdir -p $RPM_BUILD_ROOT/etc/logrotate.d
-install -m 0644 dracut.logrotate $RPM_BUILD_ROOT/etc/logrotate.d/dracut_log
+# FIXME: remove after F19
+%if 0%{?fedora} || 0%{?rhel} > 6
+mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/kernel/postinst.d
+install -m 0755 51-dracut-rescue-postinst.sh $RPM_BUILD_ROOT%{_sysconfdir}/kernel/postinst.d/51-dracut-rescue-postinst.sh
+%endif
+
+mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
+install -m 0644 dracut.logrotate $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/dracut_log
# create compat symlink
mkdir -p $RPM_BUILD_ROOT/sbin
@@ -262,11 +269,11 @@ rm -rf $RPM_BUILD_ROOT
%{dracutlibdir}/dracut-logger.sh
%{dracutlibdir}/dracut-initramfs-restore
%{dracutlibdir}/dracut-install
-%config(noreplace) /etc/dracut.conf
+%config(noreplace) %{_sysconfdir}/dracut.conf
%if 0%{?fedora} || 0%{?suse_version} || 0%{?rhel}
%{dracutlibdir}/dracut.conf.d/01-dist.conf
%endif
-%dir /etc/dracut.conf.d
+%dir %{_sysconfdir}/dracut.conf.d
%dir %{dracutlibdir}/dracut.conf.d
%{_mandir}/man8/dracut.8*
%{_mandir}/man8/*service.8*
@@ -329,7 +336,7 @@ rm -rf $RPM_BUILD_ROOT
%{dracutlibdir}/modules.d/99fs-lib
%{dracutlibdir}/modules.d/99img-lib
%{dracutlibdir}/modules.d/99shutdown
-%config(noreplace) /etc/logrotate.d/dracut_log
+%config(noreplace) %{_sysconfdir}/logrotate.d/dracut_log
%attr(0644,root,root) %ghost %config(missingok,noreplace) %{_localstatedir}/log/dracut.log
%dir %{_sharedstatedir}/initramfs
%if %{defined _unitdir}
@@ -339,6 +346,7 @@ rm -rf $RPM_BUILD_ROOT
%if 0%{?fedora} || 0%{?rhel} > 6
%{_prefix}/lib/kernel/install.d/50-dracut.install
%{_prefix}/lib/kernel/install.d/51-dracut-rescue.install
+%{_sysconfdir}/kernel/postinst.d/51-dracut-rescue-postinst.sh
%endif
%files network