summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharlie Shepherd <masterdriverz@gentoo.org>2006-12-17 11:07:56 +0000
committerCharlie Shepherd <masterdriverz@gentoo.org>2006-12-17 11:07:56 +0000
commite40a4277ca3e0b728521bc3774f734f72ab63c1a (patch)
tree264fe5c00a7e61ca3bf68d1a0c9a85f3c1f740ac
parentDropped old versions. Added note for people having the pg-hier USE-flag set. (diff)
downloadgentoo-2-e40a4277ca3e0b728521bc3774f734f72ab63c1a.tar.gz
gentoo-2-e40a4277ca3e0b728521bc3774f734f72ab63c1a.tar.bz2
gentoo-2-e40a4277ca3e0b728521bc3774f734f72ab63c1a.zip
Add patch to fix compilation under gcc-4; thanks to Phillip Lemon for the patch; bug 148091
(Portage version: 2.1.2_rc3-r1)
-rw-r--r--net-misc/mknbi/ChangeLog7
-rw-r--r--net-misc/mknbi/files/mknbi-1.4.4-gcc4.patch27
-rw-r--r--net-misc/mknbi/mknbi-1.4.4.ebuild15
3 files changed, 40 insertions, 9 deletions
diff --git a/net-misc/mknbi/ChangeLog b/net-misc/mknbi/ChangeLog
index 6f40a53127fa..a6164babf6df 100644
--- a/net-misc/mknbi/ChangeLog
+++ b/net-misc/mknbi/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for net-misc/mknbi
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/mknbi/ChangeLog,v 1.15 2006/12/09 12:05:10 masterdriverz Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/mknbi/ChangeLog,v 1.16 2006/12/17 11:07:56 masterdriverz Exp $
+
+ 17 Dec 2006; Charlie Shepherd <masterdriverz@gentoo.org>
+ +files/mknbi-1.4.4-gcc4.patch, mknbi-1.4.4.ebuild:
+ Add patch to fix compilation under gcc-4; thanks to Phillip Lemon for the
+ patch; bug 148091
09 Dec 2006; Charlie Shepherd <masterdriverz@gentoo.org>
-mknbi-1.2.11.ebuild, -mknbi-1.2.12.ebuild, -mknbi-1.4.0.ebuild,
diff --git a/net-misc/mknbi/files/mknbi-1.4.4-gcc4.patch b/net-misc/mknbi/files/mknbi-1.4.4-gcc4.patch
new file mode 100644
index 000000000000..5c7c58386653
--- /dev/null
+++ b/net-misc/mknbi/files/mknbi-1.4.4-gcc4.patch
@@ -0,0 +1,27 @@
+diff -ruN mknbi-1.4.4/nfl.c mknbi-1.4.4.thor/nfl.c
+--- mknbi-1.4.4/nfl.c 2003-09-22 16:47:08.000000000 +0200
++++ mknbi-1.4.4.thor/nfl.c 2006-05-19 13:36:42.000000000 +0200
+@@ -666,7 +666,7 @@
+ if (bhdr->b_signature != ELF_BHDR_MAGIC) {
+ return;
+ }
+-
++ /* probably breaks nothing, but why declare unsigned char and make cast to (signed) char??? */
+ note = ((char *)bhdr) + sizeof(*bhdr);
+ end = ((char *)bhdr) + bhdr->b_size;
+ while (note < end) {
+diff -ruN mknbi-1.4.4/nfl.h mknbi-1.4.4.thor/nfl.h
+--- mknbi-1.4.4/nfl.h 2003-01-12 09:39:03.000000000 +0100
++++ mknbi-1.4.4.thor/nfl.h 2006-05-19 13:36:42.000000000 +0200
+@@ -182,7 +182,10 @@
+ extern int auto_fill;
+
+ /* This variable specifies which console should be used. */
+-extern int terminal;
++/* Decide if you want static _or_ external!
++ gcc-4 finally starts complaining about this nonsense.
++ (plus: no file besides nfl.c uses this header anyway...)
++extern int terminal; */
+
+ #define TERMINAL_CONSOLE (1 << 0) /* keyboard and screen */
+ #define TERMINAL_SERIAL (1 << 1) /* serial console */
diff --git a/net-misc/mknbi/mknbi-1.4.4.ebuild b/net-misc/mknbi/mknbi-1.4.4.ebuild
index c34d43437229..48fd3d0cec77 100644
--- a/net-misc/mknbi/mknbi-1.4.4.ebuild
+++ b/net-misc/mknbi/mknbi-1.4.4.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/mknbi/mknbi-1.4.4.ebuild,v 1.2 2006/12/09 12:05:10 masterdriverz Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/mknbi/mknbi-1.4.4.ebuild,v 1.3 2006/12/17 11:07:56 masterdriverz Exp $
inherit toolchain-funcs eutils
@@ -22,19 +22,18 @@ src_unpack() {
unpack ${A}
cd "${S}"
epatch "${FILESDIR}"/mknbi-1.4.3-nossp.patch
-}
-
-src_compile() {
+ epatch "${FILESDIR}"/${P}-gcc4.patch
sed -i -e "s:\/usr\/local:\/usr:" Makefile
#apply modifications to CFLAGS to fix for gcc 3.4: bug #64049
if [ "`gcc-major-version`" -ge "3" -a "`gcc-minor-version`" -ge "4" ]
then
- sed -i -e "s:\-mcpu:\-mtune:" Makefile
- sed -i -e "s:CFLAGS=:CFLAGS= -minline-all-stringops:" Makefile
+ sed -i -e 's:\-mcpu:\-mtune:' Makefile
+ sed -i -e 's:CFLAGS=:CFLAGS= -minline-all-stringops:' Makefile
+ fi
+ if [ "`gcc-major-version`" = "4" ]; then
+ sed -i -e 's:\-fno-stack-protector-all::' Makefile
fi
-
- emake || die "Compile failed"
}
src_install() {