Accepting request 140064 from home:elvigia:branches:Base:System

- Fix factory breakage on udev and systemd rules.

OBS-URL: https://build.opensuse.org/request/show/140064
OBS-URL: https://build.opensuse.org/package/show/Base:System/mdadm?expand=0&rev=79
This commit is contained in:
Cristian Rodríguez 2012-11-04 02:24:36 +00:00 committed by Git OBS Bridge
parent 15ad866b8c
commit 3b06425b46
2 changed files with 30 additions and 22 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sun Nov 4 01:43:34 UTC 2012 - crrodriguez@opensuse.org
- Fix factory breakage on udev and systemd rules.
-------------------------------------------------------------------
Thu Oct 25 23:18:19 UTC 2012 - nfbrown@suse.com

View File

@ -20,7 +20,10 @@ Name: mdadm
Version: 3.2.6
Release: 0
BuildRequires: binutils-devel
BuildRequires: pkgconfig
BuildRequires: sgmltool
BuildRequires: pkgconfig(libudev)
BuildRequires: pkgconfig(systemd)
PreReq: %fillup_prereq %insserv_prereq /sbin/mkinitrd
Recommends: cron
Recommends: smtp_daemon
@ -40,6 +43,9 @@ Source6: mkinitrd-boot.sh
Source7: mdadm.cron
Source8: mdadm.shutdown
%define _udevrulesdir %(pkg-config --variable=udevdir udev)/rules.d
%define _systemdshutdowndir %{_unitdir}/../system-shutdown
%description
Mdadm is a program that can be used to control Linux md devices. It is
intended to provide all the functionality of the mdtools and raidtools
@ -55,21 +61,22 @@ sgml2html Software-RAID.HOWTO.sgml
sgml2txt Software-RAID.HOWTO.sgml
%install
make install DESTDIR=$RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT%{_var}/adm/fillup-templates
install -d $RPM_BUILD_ROOT{%{_sbindir},%{_sysconfdir}/init.d}
install -m 755 %{S:4} %{S:3} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/
install -d $RPM_BUILD_ROOT/lib/mkinitrd/scripts
install -m 755 %{S:5} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/setup-md.sh
install -m 755 %{S:6} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/boot-md.sh
install -d $RPM_BUILD_ROOT/etc/cron.daily
install -m 755 %{S:7} $RPM_BUILD_ROOT/etc/cron.daily/mdadm
install -m 644 %{S:2} $RPM_BUILD_ROOT%{_var}/adm/fillup-templates/
ln -sf ../../etc/init.d/mdadmd $RPM_BUILD_ROOT/%{_sbindir}/rcmdadmd
install -d $RPM_BUILD_ROOT/lib/udev/rules.d
install -m 644 udev-md-raid.rules $RPM_BUILD_ROOT/lib/udev/rules.d/64-md-raid.rules
install -d $RPM_BUILD_ROOT/lib/systemd/system-shutdown
install -m 755 %{S:8} $RPM_BUILD_ROOT/lib/systemd/system-shutdown/mdadm.shutdown
make install DESTDIR=%{buildroot}
rm -rf %{buildroot}/lib/udev
install -d %{buildroot}%{_var}/adm/fillup-templates
install -d %{buildroot}{%{_sbindir},%{_sysconfdir}/init.d}
install -m 755 %{S:4} %{S:3} %{buildroot}%{_sysconfdir}/init.d/
install -d %{buildroot}/lib/mkinitrd/scripts
install -m 755 %{S:5} %{buildroot}/lib/mkinitrd/scripts/setup-md.sh
install -m 755 %{S:6} %{buildroot}/lib/mkinitrd/scripts/boot-md.sh
install -d %{buildroot}/etc/cron.daily
install -m 755 %{S:7} %{buildroot}/etc/cron.daily/mdadm
install -m 644 %{S:2} %{buildroot}%{_var}/adm/fillup-templates/
ln -sf ../../etc/init.d/mdadmd %{buildroot}/%{_sbindir}/rcmdadmd
install -d %{buildroot}%{_udevrulesdir}
install -m 644 udev-md-raid.rules %{buildroot}%{_udevrulesdir}/64-md-raid.rules
install -d %{buildroot}%{_systemdshutdowndir}
install -m 755 %{S:8} %{buildroot}%{_systemdshutdowndir}/mdadm.shutdown
%post
[ -x /sbin/mkinitrd_setup ] && mkinitrd_setup
@ -98,7 +105,7 @@ fi
%stop_on_removal mdadmd
%clean
rm -rf $RPM_BUILD_ROOT
rm -rf %{buildroot}
%files
%defattr(-,root,root)
@ -113,14 +120,10 @@ rm -rf $RPM_BUILD_ROOT
%dir /lib/mkinitrd/scripts
/lib/mkinitrd/scripts/setup-md.sh
/lib/mkinitrd/scripts/boot-md.sh
%dir /lib/udev
%dir /lib/udev/rules.d
/lib/udev/rules.d/64-md-raid.rules
%{_udevrulesdir}/64-md-raid.rules
%dir /etc
%dir /etc/cron.daily
/etc/cron.daily/mdadm
%dir /lib/systemd
%dir /lib/systemd/system-shutdown
/lib/systemd/system-shutdown/mdadm.shutdown
%{_systemdshutdowndir}/mdadm.shutdown
%changelog