diff --git a/mdadm-destdir.patch b/mdadm-destdir.patch new file mode 100644 index 0000000..0d816fa --- /dev/null +++ b/mdadm-destdir.patch @@ -0,0 +1,11 @@ +--- Makefile ++++ Makefile +@@ -199,7 +199,7 @@ + $(INSTALL) -D -m 644 mdadm.conf.5 $(DESTDIR)$(MAN5DIR)/mdadm.conf.5 + + install-udev: udev-md-raid.rules +- $(INSTALL) -D -m 644 udev-md-raid.rules /lib/udev/rules.d/64-md-raid.rules ++ $(INSTALL) -D -m 644 udev-md-raid.rules $(DESTDIR)/lib/udev/rules.d/64-md-raid.rules + + uninstall: + rm -f $(DESTDIR)$(MAN8DIR)/mdadm.8 md.4 $(DESTDIR)$(MAN4DIR)/md.4 $(DESTDIR)$(MAN5DIR)/mdadm.conf.5 $(DESTDIR)$(BINDIR)/mdadm diff --git a/mdadm-overflow.patch b/mdadm-overflow.patch new file mode 100644 index 0000000..d92cd1f --- /dev/null +++ b/mdadm-overflow.patch @@ -0,0 +1,11 @@ +--- mdopen.c ++++ mdopen.c +@@ -88,7 +88,7 @@ + if (chmod(name, stb2.st_mode & 07777)) + perror("chmod"); + } else { +- snprintf(sym, 10000, "%s%s%d", orig, odig?"p":"", i); ++ snprintf(sym, 1024, "%s%s%d", orig, odig?"p":"", i); + symlink(sym, name); + } + stat(name, &stb2); diff --git a/mdadm.changes b/mdadm.changes index 09d3034..1e94a52 100644 --- a/mdadm.changes +++ b/mdadm.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri Nov 7 02:58:40 CET 2008 - ro@suse.de + +- buildfix: add missing DESTDIR to Makefile for udev rule +- fix len in snprintf to silence compiler warning about potential + overflow + ------------------------------------------------------------------- Thu Nov 6 03:22:50 CET 2008 - nfbrown@suse.de diff --git a/mdadm.spec b/mdadm.spec index 9c076a6..58ffecb 100644 --- a/mdadm.spec +++ b/mdadm.spec @@ -20,7 +20,7 @@ Name: mdadm Version: 3.0 -Release: 4 +Release: 5 %define ver 3.0-devel2 BuildRequires: sgmltool PreReq: %fillup_prereq %insserv_prereq @@ -34,6 +34,8 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build Source: %{name}-%{ver}.tar.bz2 Patch1: super-intel-undefined-operation.patch Patch2: mdmon-ia64-clone.patch +Patch3: mdadm-destdir.patch +Patch4: mdadm-overflow.patch Source1: Software-RAID.HOWTO.tar.bz2 Source2: sysconfig.mdadm Source3: mdadmd @@ -56,6 +58,8 @@ Authors: %setup -q -a1 -n %{name}-%{ver} %patch1 %patch2 +%patch3 +%patch4 %build %{suse_update_config -f} @@ -141,6 +145,10 @@ rm -rf $RPM_BUILD_ROOT /lib/mkinitrd/scripts/boot-md.sh %changelog +* Fri Nov 07 2008 ro@suse.de +- buildfix: add missing DESTDIR to Makefile for udev rule +- fix len in snprintf to silence compiler warning about potential + overflow * Thu Nov 06 2008 nfbrown@suse.de - Update from mdadm-3.0-devel1 to mdadm-3.0-devel2. This includes various bug fixes and enhancements to the