diff options
author | Mike Frysinger <vapier@gentoo.org> | 2005-04-08 04:03:56 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2005-04-08 04:03:56 +0000 |
commit | f9462006cf62d784f15f9f0eaa1261cd30a28abe (patch) | |
tree | 2868d904d47d7ac5bf4505d222ee1610fe453447 /games-simulation | |
parent | Add a patch to work around a gcc-3.3 bug #85780. (diff) | |
download | gentoo-2-f9462006cf62d784f15f9f0eaa1261cd30a28abe.tar.gz gentoo-2-f9462006cf62d784f15f9f0eaa1261cd30a28abe.tar.bz2 gentoo-2-f9462006cf62d784f15f9f0eaa1261cd30a28abe.zip |
patch to work around a gcc-3.3 bug #85780
(Portage version: 2.0.51.19)
Diffstat (limited to 'games-simulation')
-rw-r--r-- | games-simulation/searchandrescue/files/searchandrescue-0.8.1-gcc33.patch | 31 | ||||
-rw-r--r-- | games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild | 13 |
2 files changed, 38 insertions, 6 deletions
diff --git a/games-simulation/searchandrescue/files/searchandrescue-0.8.1-gcc33.patch b/games-simulation/searchandrescue/files/searchandrescue-0.8.1-gcc33.patch new file mode 100644 index 000000000000..b1cbe3ff9e65 --- /dev/null +++ b/games-simulation/searchandrescue/files/searchandrescue-0.8.1-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 + +--- sar/string.cpp ++++ sar/string.cpp +@@ -38,3 +38,5 @@ + #endif ++#ifndef _GNU_SOURCE + char *strcasestr(const char *haystack, const char *needle); ++#endif + int strpfx(const char *s, const char *pfx); +@@ -222,3 +223,4 @@ + */ ++#ifndef _GNU_SOURCE + char *strcasestr(const char *haystack, const char *needle) + { +@@ -281,6 +281,7 @@ + + return(NULL); + } ++#endif + + /* + * Checks if string pfx is a prefix of string s. diff --git a/games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild b/games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild index de6ef7bfa14e..d87e0ec6f0b0 100644 --- a/games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild +++ b/games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild @@ -1,8 +1,8 @@ -# Copyright 1999-2004 Gentoo Foundation +# Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild,v 1.5 2004/06/24 23:23:15 agriffis Exp $ +# $Header: /var/cvsroot/gentoo-x86/games-simulation/searchandrescue/searchandrescue-0.8.1.ebuild,v 1.6 2005/04/08 04:03:56 vapier Exp $ -inherit games +inherit games eutils MY_PN=SearchAndRescue DESCRIPTION="aircraft based rescue simulator" @@ -12,7 +12,7 @@ SRC_URI="ftp://wolfpack.twu.net/users/wolfpack/${MY_PN}-${PV}.tgz LICENSE="GPL-2" SLOT="0" -KEYWORDS="x86 ppc" +KEYWORDS="ppc x86" IUSE="joystick" DEPEND="virtual/x11 @@ -25,7 +25,8 @@ src_unpack() { unpack ${MY_PN}-${PV}.tgz mkdir data ; cd data unpack ${MY_PN}-data-${PV}.tgz - cd ${S} + cd "${S}" + epatch "${FILESDIR}"/${P}-gcc33.patch bunzip2 sar/man/${MY_PN}.6.bz2 sed -i "s:/usr/share/icons:/usr/share/icons/${PN}:g" sar/config.h sed -i '/FeatureCFLAGS.*march/s:=.*:=:g' sar/platforms.ini @@ -52,6 +53,6 @@ src_install() { dodoc AUTHORS HACKING README cd ${WORKDIR}/data dodir ${GAMES_DATADIR}/${MY_PN} - cp -r * ${D}/${GAMES_DATADIR}/${MY_PN}/ + cp -r * "${D}"/${GAMES_DATADIR}/${MY_PN}/ || die prepgamesdirs } |