diff options
author | Mike Frysinger <vapier@gentoo.org> | 2006-06-25 00:51:37 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2006-06-25 00:51:37 +0000 |
commit | 260b966f197e53d9cf3c82c177d4e44321f8f066 (patch) | |
tree | d63bd7455472648cc6234bbf4daca2b5f6932fdb /sys-fs | |
parent | Do not strip binaries in the build process, leave this to portage. Quote vari... (diff) | |
download | gentoo-2-260b966f197e53d9cf3c82c177d4e44321f8f066.tar.gz gentoo-2-260b966f197e53d9cf3c82c177d4e44321f8f066.tar.bz2 gentoo-2-260b966f197e53d9cf3c82c177d4e44321f8f066.zip |
Fix up strict alias warnings #137440 by Andrew Gaffney.
(Portage version: 2.1.1_pre1-r2)
Diffstat (limited to 'sys-fs')
-rw-r--r-- | sys-fs/mdadm/ChangeLog | 8 | ||||
-rw-r--r-- | sys-fs/mdadm/files/digest-mdadm-2.5-r1 | 3 | ||||
-rw-r--r-- | sys-fs/mdadm/files/mdadm-2.5-pointer-magic.patch | 35 | ||||
-rw-r--r-- | sys-fs/mdadm/mdadm-2.5-r1.ebuild | 51 |
4 files changed, 96 insertions, 1 deletions
diff --git a/sys-fs/mdadm/ChangeLog b/sys-fs/mdadm/ChangeLog index 2eb275b0c533..e5a7039f45d6 100644 --- a/sys-fs/mdadm/ChangeLog +++ b/sys-fs/mdadm/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for sys-fs/mdadm # Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-fs/mdadm/ChangeLog,v 1.31 2006/06/25 00:21:12 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-fs/mdadm/ChangeLog,v 1.32 2006/06/25 00:51:37 vapier Exp $ + +*mdadm-2.5-r1 (25 Jun 2006) + + 25 Jun 2006; Mike Frysinger <vapier@gentoo.org> + +files/mdadm-2.5-pointer-magic.patch, +mdadm-2.5-r1.ebuild: + Fix up strict alias warnings #137440 by Andrew Gaffney. 25 Jun 2006; Mike Frysinger <vapier@gentoo.org> +files/mdadm-2.5-build.patch, files/mdadm-2.5-ssl-cleanup.patch, diff --git a/sys-fs/mdadm/files/digest-mdadm-2.5-r1 b/sys-fs/mdadm/files/digest-mdadm-2.5-r1 new file mode 100644 index 000000000000..d5fea9e68ed8 --- /dev/null +++ b/sys-fs/mdadm/files/digest-mdadm-2.5-r1 @@ -0,0 +1,3 @@ +MD5 52b7264d6d06258c77439a9ed8dee5e5 mdadm-2.5.tar.bz2 133036 +RMD160 b00da521aad2bd3e3f3e2df7192b6fd71d29ee67 mdadm-2.5.tar.bz2 133036 +SHA256 b6ec7ff2da406b09fb6231238969db334c3881c2470c3e344ae9b0a98ceabff1 mdadm-2.5.tar.bz2 133036 diff --git a/sys-fs/mdadm/files/mdadm-2.5-pointer-magic.patch b/sys-fs/mdadm/files/mdadm-2.5-pointer-magic.patch new file mode 100644 index 000000000000..fc72667a284b --- /dev/null +++ b/sys-fs/mdadm/files/mdadm-2.5-pointer-magic.patch @@ -0,0 +1,35 @@ +Clean up strict alias warnings: +config.c: In function 'free_line': +config.c:192: warning: dereferencing type-punned pointer will break strict-aliasing rules +config.c:192: warning: dereferencing type-punned pointer will break strict-aliasing rules + +http://bugs.gentoo.org/137440 + +--- mdadm-2.5/dlink.c ++++ mdadm-2.5/dlink.c +@@ -8,6 +8,7 @@ + #ifdef __dietlibc__ + char *strncpy(char *dest, const char *src, size_t n) __THROW; + #endif ++#define __IN_DLINK + #include "dlink.h" + + +--- mdadm-2.5/dlink.h ++++ mdadm-2.5/dlink.h +@@ -12,8 +12,13 @@ + #define dl_new(t) ((t*)dl_alloc(sizeof(t))) + #define dl_newv(t,n) ((t*)dl_alloc(sizeof(t)*n)) + +-#define dl_next(p) *((void**)&(((struct __dl_head*)(p))[-1].dh_next)) +-#define dl_prev(p) *((void**)&(((struct __dl_head*)(p))[-1].dh_prev)) ++#ifdef __IN_DLINK ++#define __DLINK_CAST ++#else ++#define __DLINK_CAST (void*) ++#endif ++#define dl_next(p) (__DLINK_CAST (((struct __dl_head*)(p))[-1].dh_next)) ++#define dl_prev(p) (__DLINK_CAST (((struct __dl_head*)(p))[-1].dh_prev)) + + void *dl_head(void); + char *dl_strdup(char *); diff --git a/sys-fs/mdadm/mdadm-2.5-r1.ebuild b/sys-fs/mdadm/mdadm-2.5-r1.ebuild new file mode 100644 index 000000000000..2b32f8ea4c41 --- /dev/null +++ b/sys-fs/mdadm/mdadm-2.5-r1.ebuild @@ -0,0 +1,51 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-fs/mdadm/mdadm-2.5-r1.ebuild,v 1.1 2006/06/25 00:51:37 vapier Exp $ + +inherit eutils flag-o-matic + +DESCRIPTION="A useful tool for running RAID systems - it can be used as a replacement for the raidtools" +HOMEPAGE="http://cgi.cse.unsw.edu.au/~neilb/mdadm" +SRC_URI="mirror://kernel/linux/utils/raid/mdadm/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86" +IUSE="static ssl" + +RDEPEND="ssl? ( dev-libs/openssl )" +DEPEND="${RDEPEND} + >=sys-apps/portage-2.0.51" + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}"/${P}-ssl-cleanup.patch + epatch "${FILESDIR}"/${PN}-2.3.1-endian.patch #122269 + epatch "${FILESDIR}"/${PN}-1.9.0-dont-make-man.patch + epatch "${FILESDIR}"/${PN}-2.4.1-syslog-updates.patch + epatch "${FILESDIR}"/${PN}-2.5-build.patch #137823 + epatch "${FILESDIR}"/${PN}-2.5-pointer-magic.patch #137440 + use static && append-ldflags -static + use ssl && export USE_SSL=1 || export USE_SSL=0 + sed -i -e 1iUSE_SSL=${USE_SSL} Makefile +} + +src_compile() { + emake \ + CWFLAGS="-Wall" \ + CXFLAGS="${CFLAGS}" \ + || die "emake failed" +} + +src_install() { + emake DESTDIR="${D}" install || die "make install failed" + exeinto /$(get_libdir)/rcscripts/addons + doexe "${FILESDIR}"/raid-{start,stop}.sh || die "addon failed" + dodoc INSTALL TODO "ANNOUNCE-${PV}" + + insinto /etc + newins mdadm.conf-example mdadm.conf + newinitd "${FILESDIR}"/mdadm.rc mdadm || die + newconfd "${FILESDIR}"/mdadm.confd mdadm || die +} |