From 64ace369f5a23ca1bc5f9b17048ad89036d802f3 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Fri, 8 Apr 2005 04:09:24 +0000 Subject: patch to work around a gcc-3.3 bug #85780 (Portage version: 2.0.51.19) --- .../xshipwars/files/xshipwars-1.34.0-gcc33.patch | 31 ++++++++++++++++++++++ games-action/xshipwars/xshipwars-1.34.0.ebuild | 4 ++- 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 games-action/xshipwars/files/xshipwars-1.34.0-gcc33.patch (limited to 'games-action') diff --git a/games-action/xshipwars/files/xshipwars-1.34.0-gcc33.patch b/games-action/xshipwars/files/xshipwars-1.34.0-gcc33.patch new file mode 100644 index 000000000000..f64de08f4d2a --- /dev/null +++ b/games-action/xshipwars/files/xshipwars-1.34.0-gcc33.patch @@ -0,0 +1,31 @@ +Work around a gcc-3.3.x bug where redefining prototypes with different +__THROW / attribute(nonnull) markings throws an error: + +string.cpp:31: error: declaration of `char* strcasestr(const char*, const char*)' throws different exceptions +../include/string.h:46: error: than previous declaration `char* strcasestr(const char*, const char*) throw ()' + +basically we just use the glibc strcasestr() instead of the internal one. + +http://bugs.gentoo.org/show_bug.cgi?id=85780 + +--- global/string.cpp ++++ global/string.cpp +@@ -37,3 +37,5 @@ + #endif ++#ifndef _GNU_SOURCE + char *strcasestr(const char *haystack, const char *needle); ++#endif + int strpfx(const char *s, const char *pfx); +@@ -221,3 +224,4 @@ + */ ++#ifndef _GNU_SOURCE + char *strcasestr(const char *haystack, const char *needle) + { +@@ -274,6 +277,7 @@ + + return(NULL); + } ++#endif + + /* + * Checks if string pfx is a prefix of string s. diff --git a/games-action/xshipwars/xshipwars-1.34.0.ebuild b/games-action/xshipwars/xshipwars-1.34.0.ebuild index b8e5c3b91ed3..897c9318ed83 100644 --- a/games-action/xshipwars/xshipwars-1.34.0.ebuild +++ b/games-action/xshipwars/xshipwars-1.34.0.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/games-action/xshipwars/xshipwars-1.34.0.ebuild,v 1.11 2005/03/19 18:20:23 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/games-action/xshipwars/xshipwars-1.34.0.ebuild,v 1.12 2005/04/08 04:09:24 vapier Exp $ inherit toolchain-funcs eutils games @@ -25,6 +25,8 @@ S=${WORKDIR}/${MY_P} src_unpack() { unpack ${MY_P}.tar.bz2 + cd "${S}" + epatch "${FILESDIR}"/${P}-gcc33.patch } src_compile() { -- cgit v1.2.3-65-gdbad