diff options
Diffstat (limited to 'package/mdadm/patches')
-rw-r--r-- | package/mdadm/patches/patch-Makefile | 79 | ||||
-rw-r--r-- | package/mdadm/patches/patch-platform-intel_c | 34 |
2 files changed, 18 insertions, 95 deletions
diff --git a/package/mdadm/patches/patch-Makefile b/package/mdadm/patches/patch-Makefile index b669eab54..7e11c9f8a 100644 --- a/package/mdadm/patches/patch-Makefile +++ b/package/mdadm/patches/patch-Makefile @@ -1,78 +1,35 @@ ---- mdadm-3.1.1.orig/Makefile 2009-11-16 23:55:41.000000000 +0100 -+++ mdadm-3.1.1/Makefile 2011-11-09 16:50:02.083123679 +0100 +--- mdadm-3.2.5.orig/Makefile 2012-05-18 09:10:03.000000000 +0200 ++++ mdadm-3.2.5/Makefile 2012-07-25 13:51:12.000000000 +0200 @@ -42,7 +42,7 @@ KLIBC_GCC = gcc -nostdinc -iwithprefix i CC = $(CROSS_COMPILE)gcc CXFLAGS = -ggdb --CWFLAGS = -Wall -Werror -Wstrict-prototypes -+CWFLAGS = -Wall -Wstrict-prototypes +-CWFLAGS = -Wall -Werror -Wstrict-prototypes -Wextra -Wno-unused-parameter ++CWFLAGS = -Wall -Wstrict-prototypes -Wextra -Wno-unused-parameter ifdef WARN_UNUSED CWFLAGS += -Wp,-D_FORTIFY_SOURCE=2 -O endif -@@ -58,7 +58,8 @@ CONFFILE = $(SYSCONFDIR)/mdadm.conf - CONFFILE2 = $(SYSCONFDIR)/mdadm/mdadm.conf - MAILCMD =/usr/sbin/sendmail -t - CONFFILEFLAGS = -DCONFFILE=\"$(CONFFILE)\" -DCONFFILE2=\"$(CONFFILE2)\" --CFLAGS = $(CWFLAGS) $(CXFLAGS) -DSendmail=\""$(MAILCMD)"\" $(CONFFILEFLAGS) +@@ -76,7 +76,8 @@ FAILED_SLOTS_DIR = /run/mdadm/failed-slo + DIRFLAGS = -DMAP_DIR=\"$(MAP_DIR)\" -DMAP_FILE=\"$(MAP_FILE)\" + DIRFLAGS += -DMDMON_DIR=\"$(MDMON_DIR)\" + DIRFLAGS += -DFAILED_SLOTS_DIR=\"$(FAILED_SLOTS_DIR)\" +-CFLAGS = $(CWFLAGS) $(CXFLAGS) -DSendmail=\""$(MAILCMD)"\" $(CONFFILEFLAGS) $(DIRFLAGS) +CFLAGS ?= -+CFLAGS += $(CWFLAGS) -DSendmail=\""$(MAILCMD)"\" $(CONFFILEFLAGS) ++CFLAGS += $(CWFLAGS) $(CXFLAGS) -DSendmail=\""$(MAILCMD)"\" $(CONFFILEFLAGS) $(DIRFLAGS) - # If you want a static binary, you might uncomment these - # LDFLAGS = -static -@@ -105,7 +106,7 @@ ASSEMBLE_SRCS += $(ASSEMBLE_AUTO_SRCS) - ASSEMBLE_FLAGS += -DMDASSEMBLE_AUTO - endif - --all : mdadm mdmon mdadm.man md.man mdadm.conf.man mdmon.man -+all : mdadm mdmon - - everything: all mdadm.static swap_super test_stripe \ - mdassemble mdassemble.auto mdassemble.static mdassemble.man \ -@@ -186,29 +187,36 @@ sha1.o : sha1.c sha1.h md5.h + # The glibc TLS ABI requires applications that call clone(2) to set up + # TLS data structures, use pthreads until mdmon implements this support +@@ -231,9 +232,10 @@ $(MON_OBJS) : $(INCL) mdmon.h + sha1.o : sha1.c sha1.h md5.h $(CC) $(CFLAGS) -DHAVE_STDINT_H -o sha1.o -c sha1.c - install : mdadm mdmon install-man install-udev +-install : mdadm mdmon install-man install-udev - $(INSTALL) -D $(STRIP) -m 755 mdadm $(DESTDIR)$(BINDIR)/mdadm - $(INSTALL) -D $(STRIP) -m 755 mdmon $(DESTDIR)$(BINDIR)/mdmon -+ $(INSTALL) -d $(DESTDIR)$(BINDIR) ++install : mdadm mdmon ++ $(INSTALL) -d -m 755 $(DESTDIR)$(BINDIR) + $(INSTALL) -m 755 mdadm $(DESTDIR)$(BINDIR)/mdadm + $(INSTALL) -m 755 mdmon $(DESTDIR)$(BINDIR)/mdmon install-static : mdadm.static install-man -- $(INSTALL) -D $(STRIP) -m 755 mdadm.static $(DESTDIR)$(BINDIR)/mdadm -+ $(INSTALL) -d $(DESTDIR)$(BINDIR) -+ $(INSTALL) $(STRIP) -m 755 mdadm.static $(DESTDIR)$(BINDIR)/mdadm - - install-tcc : mdadm.tcc install-man -- $(INSTALL) -D $(STRIP) -m 755 mdadm.tcc $(DESTDIR)$(BINDIR)/mdadm -+ $(INSTALL) -d $(DESTDIR)$(BINDIR) -+ $(INSTALL) $(STRIP) -m 755 mdadm.tcc $(DESTDIR)$(BINDIR)/mdadm - - install-uclibc : mdadm.uclibc install-man -- $(INSTALL) -D $(STRIP) -m 755 mdadm.uclibc $(DESTDIR)$(BINDIR)/mdadm -+ $(INSTALL) -d $(DESTDIR)$(BINDIR) -+ $(INSTALL) $(STRIP) -m 755 mdadm.uclibc $(DESTDIR)$(BINDIR)/mdadm - - install-klibc : mdadm.klibc install-man -- $(INSTALL) -D $(STRIP) -m 755 mdadm.klibc $(DESTDIR)$(BINDIR)/mdadm -+ $(INSTALL) -d $(DESTDIR)$(BINDIR) -+ $(INSTALL) $(STRIP) -m 755 mdadm.klibc $(DESTDIR)$(BINDIR)/mdadm - - install-man: mdadm.8 md.4 mdadm.conf.5 mdmon.8 -- $(INSTALL) -D -m 644 mdadm.8 $(DESTDIR)$(MAN8DIR)/mdadm.8 -- $(INSTALL) -D -m 644 mdmon.8 $(DESTDIR)$(MAN8DIR)/mdmon.8 -- $(INSTALL) -D -m 644 md.4 $(DESTDIR)$(MAN4DIR)/md.4 -- $(INSTALL) -D -m 644 mdadm.conf.5 $(DESTDIR)$(MAN5DIR)/mdadm.conf.5 -+ $(INSTALL) -d $(DESTDIR)$(MAN8DIR) $(DESTDIR)$(MAN4DIR) $(DESTDIR)$(MAN5DIR) -+ $(INSTALL) -m 644 mdadm.8 $(DESTDIR)$(MAN8DIR)/mdadm.8 -+ $(INSTALL) -m 644 mdmon.8 $(DESTDIR)$(MAN8DIR)/mdmon.8 -+ $(INSTALL) -m 644 md.4 $(DESTDIR)$(MAN4DIR)/md.4 -+ $(INSTALL) -m 644 mdadm.conf.5 $(DESTDIR)$(MAN5DIR)/mdadm.conf.5 - - install-udev: udev-md-raid.rules -- $(INSTALL) -D -m 644 udev-md-raid.rules $(DESTDIR)/lib/udev/rules.d/64-md-raid.rules -+ $(INSTALL) -d $(DESTDIR)/lib/udev/rules.d/ -+ $(INSTALL) -m 644 udev-md-raid.rules $(DESTDIR)/lib/udev/rules.d/64-md-raid.rules - - uninstall: - rm -f $(DESTDIR)$(MAN8DIR)/mdadm.8 $(DESTDIR)$(MAN8DIR)/mdmon.8 $(DESTDIR)$(MAN4DIR)/md.4 $(DESTDIR)$(MAN5DIR)/mdadm.conf.5 $(DESTDIR)$(BINDIR)/mdadm + $(INSTALL) -D $(STRIP) -m 755 mdadm.static $(DESTDIR)$(BINDIR)/mdadm diff --git a/package/mdadm/patches/patch-platform-intel_c b/package/mdadm/patches/patch-platform-intel_c deleted file mode 100644 index 3102306e7..000000000 --- a/package/mdadm/patches/patch-platform-intel_c +++ /dev/null @@ -1,34 +0,0 @@ ---- mdadm-3.1.1.orig/platform-intel.c 2009-11-16 23:55:41.000000000 +0100 -+++ mdadm-3.1.1/platform-intel.c 2010-02-06 01:07:51.781825419 +0100 -@@ -47,6 +47,7 @@ struct sys_dev *find_driver_devices(cons - char path[256]; - char link[256]; - char *c; -+ char *rpath; - DIR *driver_dir; - struct dirent *de; - struct sys_dev *head = NULL; -@@ -87,7 +88,9 @@ struct sys_dev *find_driver_devices(cons - /* generate canonical path name for the device */ - sprintf(path, "/sys/bus/%s/drivers/%s/%s", - bus, driver, de->d_name); -- list->path = canonicalize_file_name(path); -+ -+ rpath = malloc(PATH_MAX); -+ list->path = realpath(path, rpath); - list->next = NULL; - } - closedir(driver_dir); -@@ -203,9 +206,11 @@ const struct imsm_orom *find_imsm_orom(v - char *devt_to_devpath(dev_t dev) - { - char device[40]; -+ char *rpath; - - sprintf(device, "/sys/dev/block/%d:%d/device", major(dev), minor(dev)); -- return canonicalize_file_name(device); -+ rpath = malloc(PATH_MAX); -+ return realpath(device, rpath); - } - - static char *diskfd_to_devpath(int fd) |