diff options
author | Mike Frysinger <vapier@gentoo.org> | 2005-05-19 22:16:16 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2005-05-19 22:16:16 +0000 |
commit | 6f92a13589dff17ccd1cbe4ffe706ba99ec40ea8 (patch) | |
tree | 3cc5bc481ff0be35848fde1ea1fd77961ceddef1 /sys-fs/raidtools | |
parent | sync with raidtools (diff) | |
download | gentoo-2-6f92a13589dff17ccd1cbe4ffe706ba99ec40ea8.tar.gz gentoo-2-6f92a13589dff17ccd1cbe4ffe706ba99ec40ea8.tar.bz2 gentoo-2-6f92a13589dff17ccd1cbe4ffe706ba99ec40ea8.zip |
Dont be so noisy during bootup #93039.
(Portage version: 2.0.51.22-r1)
Diffstat (limited to 'sys-fs/raidtools')
-rw-r--r-- | sys-fs/raidtools/ChangeLog | 11 | ||||
-rw-r--r-- | sys-fs/raidtools/files/digest-raidtools-1.00.3-r5 | 1 | ||||
-rwxr-xr-x | sys-fs/raidtools/files/raid-start.sh | 4 | ||||
-rw-r--r-- | sys-fs/raidtools/files/raidtools-1.00.3-quiet-raidstart.patch | 54 | ||||
-rw-r--r-- | sys-fs/raidtools/raidtools-1.00.3-r5.ebuild | 55 |
5 files changed, 121 insertions, 4 deletions
diff --git a/sys-fs/raidtools/ChangeLog b/sys-fs/raidtools/ChangeLog index 64faf14e2a7c..08e6053d27fa 100644 --- a/sys-fs/raidtools/ChangeLog +++ b/sys-fs/raidtools/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sys-fs/raidtools -# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/raidtools/ChangeLog,v 1.19 2005/04/07 21:50:06 plasmaroo Exp $ +# Copyright 1999-2005 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/raidtools/ChangeLog,v 1.20 2005/05/19 22:16:16 vapier Exp $ + +*raidtools-1.00.3-r5 (19 May 2005) + + 19 May 2005; Mike Frysinger <vapier@gentoo.org> + +files/raidtools-1.00.3-quiet-raidstart.patch, files/raid-start.sh, + +raidtools-1.00.3-r5.ebuild: + Dont be so noisy during bootup #93039. 07 Apr 2005; <plasmaroo@gentoo.org> files/raidtools-1.00.3-2.6.Headers.patch: diff --git a/sys-fs/raidtools/files/digest-raidtools-1.00.3-r5 b/sys-fs/raidtools/files/digest-raidtools-1.00.3-r5 new file mode 100644 index 000000000000..8b9f5451a2c5 --- /dev/null +++ b/sys-fs/raidtools/files/digest-raidtools-1.00.3-r5 @@ -0,0 +1 @@ +MD5 cb41f8093cd7381ee07adb2951cc53fa raidtools-1.00.3.tar.gz 167779 diff --git a/sys-fs/raidtools/files/raid-start.sh b/sys-fs/raidtools/files/raid-start.sh index a593885e7801..5a95bd312898 100755 --- a/sys-fs/raidtools/files/raid-start.sh +++ b/sys-fs/raidtools/files/raid-start.sh @@ -1,7 +1,7 @@ # /lib/rcscripts/addons/raid-start.sh: Setup raid volumes at boot # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/raidtools/files/raid-start.sh,v 1.3 2005/05/19 03:14:29 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/raidtools/files/raid-start.sh,v 1.4 2005/05/19 22:16:16 vapier Exp $ [[ -f /proc/mdstat ]] || exit 0 @@ -25,7 +25,7 @@ if [[ -x /sbin/raidstart && -f /etc/raidtab ]] ; then if [[ -n ${devs} ]] ; then create_devs ${devs} ebegin "Starting up RAID devices (raidtools)" - output=$(raidstart -a 2>&1) + output=$(raidstart -aq 2>&1) ret=$? [[ ${ret} -ne 0 ]] && echo "${output}" eend ${ret} diff --git a/sys-fs/raidtools/files/raidtools-1.00.3-quiet-raidstart.patch b/sys-fs/raidtools/files/raidtools-1.00.3-quiet-raidstart.patch new file mode 100644 index 000000000000..07395d7749b1 --- /dev/null +++ b/sys-fs/raidtools/files/raidtools-1.00.3-quiet-raidstart.patch @@ -0,0 +1,54 @@ +Allow people to run `raidstart -aq` and not have raidtools bitch when +it tries to start devices that are already started. This allows us to +simplify raidstarting at boot up. If the user has all their devices +autostart by the kernel, running `raidstart -a` would display a bunch +of ugly warnings about the devices already being started. Now we can +just run `raidstart -aq` and let raidtools figure out whether it needs +to start any of the devices or not. + +Note that this patch isn't exactly "clean", it's a shortcut approach +to keep patch size/maintenance down to a minimal. + +http://bugs.gentoo.org/93039 + +vapier@gentoo.org + +--- raid_io.c ++++ raid_io.c +@@ -517,3 +517,3 @@ + +-int check_active (md_cfg_entry_t *p) ++int _check_active (md_cfg_entry_t *p, int quiet) + { +@@ -531,3 +531,4 @@ + if (strstr(line, buffer) && !strstr(line, "inactive")) { +- fprintf(stderr, "%s: array is active -- run raidstop first.\n", p->md_name); ++ if (!quiet) ++ fprintf(stderr, "%s: array is active -- run raidstop first.\n", p->md_name); + fclose(fp); +--- raid_io.h ++++ raid_io.h +@@ -22,3 +22,4 @@ + extern int init_set (md_cfg_entry_t * p); +-extern int check_active (md_cfg_entry_t *p); ++extern int _check_active (md_cfg_entry_t *p, int quiet); ++#define check_active(p) _check_active(p,0) + extern int read_sb (md_cfg_entry_t *p); +--- raidstart.c ++++ raidstart.c +@@ -22,2 +22,3 @@ + #include "raidlib.h" ++#include "raid_io.h" + #include "version.h" +@@ -45,3 +46,5 @@ + char * configFile = RAID_CONFIG; ++ int quiet = 0; + struct poptOption optionsTable[] = { ++ { "quiet", 'q', 0, &quiet, 0 }, + { "all", 'a', 0, &all, 0 }, +@@ -229,3 +232,4 @@ + for (p = cfg_head; p; p = p->next) +- exit_status += handleOneConfig(func, p); ++ if (!_check_active(p, quiet)) ++ exit_status += handleOneConfig(func, p); + } else { diff --git a/sys-fs/raidtools/raidtools-1.00.3-r5.ebuild b/sys-fs/raidtools/raidtools-1.00.3-r5.ebuild new file mode 100644 index 000000000000..3a983f37c36d --- /dev/null +++ b/sys-fs/raidtools/raidtools-1.00.3-r5.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/raidtools/raidtools-1.00.3-r5.ebuild,v 1.1 2005/05/19 22:16:16 vapier Exp $ + +inherit flag-o-matic eutils + +DESCRIPTION="Linux RAID 0/1/4/5 utilities" +HOMEPAGE="http://people.redhat.com/mingo/raidtools/" +SRC_URI="http://people.redhat.com/mingo/raidtools/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="-*" +IUSE="" + +# We link statically with popt so that libpopt can +# live in /usr but keep critical raid binaries in / +DEPEND="dev-libs/popt" +RDEPEND="" + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}"/${P}-gcc33.patch + epatch "${FILESDIR}"/${P}-2.6.Headers.patch + epatch "${FILESDIR}"/${P}-mkraid.patch + epatch "${FILESDIR}"/${P}-s390x.patch + epatch "${FILESDIR}"/${P}-raidstop.patch + epatch "${FILESDIR}"/${P}-PIC.patch + epatch "${FILESDIR}"/${P}-quiet-raidstart.patch + + # Buffer overflow fix + sed -i -e "/define MAX_LINE_LENGTH/s:100:1000:" common.h + # Don't create device nodes (pisses off selinux) #73928 + sed -i \ + -e '/^CFLAGS/s:-O2:@CFLAGS@:' \ + -e "s:mknod:echo mknod means MonKey NOD:" \ + Makefile.in || die "sed Makefile.in failed" +} + +src_install() { + make install ROOTDIR="${D}" || die + insinto /$(get_libdir)/rcscripts/addons + doins "${FILESDIR}"/raid-start.sh || die "addon failed" + + exeinto /etc/cron.daily + newexe "${FILESDIR}"/raidtools.cron raidtools + + doman *.8 *.5 + dodoc README *raidtab raidreconf-HOWTO reconf.notes retry summary \ + Software-RAID.HOWTO/Software-RAID.HOWTO.txt + dohtml Software-RAID.HOWTO/Software-RAID.HOWTO.html + docinto config + dodoc *.sample +} |