summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfredo Tupone <tupone@gentoo.org>2006-09-14 07:20:20 +0000
committerAlfredo Tupone <tupone@gentoo.org>2006-09-14 07:20:20 +0000
commitfca9a12884844166141b0692a57a53d9f086b333 (patch)
treeecfefe5897863a6047b0c33350adb2f98cd62088 /games-puzzle/quadra
parentbackport sysroot stuff (diff)
downloadgentoo-2-fca9a12884844166141b0692a57a53d9f086b333.tar.gz
gentoo-2-fca9a12884844166141b0692a57a53d9f086b333.tar.bz2
gentoo-2-fca9a12884844166141b0692a57a53d9f086b333.zip
Fixing building with gcc-3 again. Bug #137714
(Portage version: 2.1.1)
Diffstat (limited to 'games-puzzle/quadra')
-rw-r--r--games-puzzle/quadra/ChangeLog7
-rw-r--r--games-puzzle/quadra/files/quadra-1.1.8-gcc3.patch33
-rw-r--r--games-puzzle/quadra/quadra-1.1.8.ebuild7
3 files changed, 35 insertions, 12 deletions
diff --git a/games-puzzle/quadra/ChangeLog b/games-puzzle/quadra/ChangeLog
index 955e13348315..a52e4cc9bed6 100644
--- a/games-puzzle/quadra/ChangeLog
+++ b/games-puzzle/quadra/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for games-puzzle/quadra
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/games-puzzle/quadra/ChangeLog,v 1.13 2006/05/31 18:55:36 tupone Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-puzzle/quadra/ChangeLog,v 1.14 2006/09/14 07:20:20 tupone Exp $
+
+ 14 Sep 2006; <tupone@gentoo.org> files/quadra-1.1.8-gcc3.patch,
+ -files/quadra-1.1.8-gcc41.patch, quadra-1.1.8.ebuild:
+ Fix building with gcc-3 again merging gcc-3 and gcc-4 patches.
+ Bug #137714 by Rafael Gustavo Gassner
31 May 2006; <Tupone@gentoo.org> +files/quadra-1.1.8-gcc41.patch,
quadra-1.1.8.ebuild:
diff --git a/games-puzzle/quadra/files/quadra-1.1.8-gcc3.patch b/games-puzzle/quadra/files/quadra-1.1.8-gcc3.patch
index 6894a004d14d..8b03e05535ad 100644
--- a/games-puzzle/quadra/files/quadra-1.1.8-gcc3.patch
+++ b/games-puzzle/quadra/files/quadra-1.1.8-gcc3.patch
@@ -1,21 +1,32 @@
-diff -urN quadra-1.1.8/skelton/include/array.h quadra-1.1.8-kacsa/skelton/include/array.h
---- quadra-1.1.8/skelton/include/array.h Sat Mar 10 17:17:54 2001
-+++ quadra-1.1.8-kacsa/skelton/include/array.h Fri May 17 17:12:12 2002
-@@ -37,7 +37,7 @@
+--- quadra-1.1.8-orig/skelton/include/array.h 2006-05-21 16:35:30.000000000 -0400
++++ quadra-1.1.8/skelton/include/array.h 2006-05-21 16:53:06.000000000 -0400
+@@ -21,6 +21,7 @@
+ #ifndef _HEADER_ARRAY
+ #define _HEADER_ARRAY
+ #include <vector>
++#include <algorithm>
+
+ #ifndef max
+ #define max(a,b) (((a) > (b)) ? (a) : (b))
+@@ -37,7 +38,9 @@
v.push_back(t);
}
void add_before(const T& t, int i) {
- v.insert(&v[i], t);
-+ v.insert(v.begin() + i, t);
++ typename std::vector<T>::iterator iter = v.begin();
++ std::advance(iter, i);
++ v.insert(iter, t);
}
bool remove_item(const T& t) {
for(int i=0; i<size(); i++)
-@@ -51,7 +51,7 @@
+@@ -51,7 +54,9 @@
v.pop_back();
}
void remove(int i) {
- v.erase(&v[i]);
-+ v.erase(v.begin() + i);
++ typename std::vector<T>::iterator iter = v.begin();
++ std::advance(iter, i);
++ v.erase(iter);
}
int size() const {
return v.size();
@@ -51,6 +62,14 @@ diff -urN quadra-1.1.8/source/net_stuff.cpp quadra-1.1.8-kacsa/source/net_stuff.
diff -urN quadra-1.1.8/source/quadra.cpp quadra-1.1.8-kacsa/source/quadra.cpp
--- quadra-1.1.8/source/quadra.cpp Fri Oct 19 23:19:31 2001
+++ quadra-1.1.8-kacsa/source/quadra.cpp Fri May 17 17:17:02 2002
+@@ -25,6 +25,7 @@
+ #include <sys/types.h>
+ #endif
+ #include <stdlib.h>
++#include <exception>
+ #include "packet.h"
+ #include "types.h"
+ #include "net.h"
@@ -2387,7 +2387,7 @@
try {
overmind.step();
diff --git a/games-puzzle/quadra/quadra-1.1.8.ebuild b/games-puzzle/quadra/quadra-1.1.8.ebuild
index 5051c4f814e0..0b868a78963c 100644
--- a/games-puzzle/quadra/quadra-1.1.8.ebuild
+++ b/games-puzzle/quadra/quadra-1.1.8.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/games-puzzle/quadra/quadra-1.1.8.ebuild,v 1.13 2006/05/31 18:55:36 tupone Exp $
+# $Header: /var/cvsroot/gentoo-x86/games-puzzle/quadra/quadra-1.1.8.ebuild,v 1.14 2006/09/14 07:20:20 tupone Exp $
inherit eutils toolchain-funcs games
@@ -22,9 +22,8 @@ DEPEND="${RDEPEND}
src_unpack() {
unpack ${A}
cd "${S}"
- [ $(gcc-major-version) == 3 ] && epatch "${FILESDIR}/${P}-gcc3.patch"
- epatch "${FILESDIR}/libpng-1.2.5.patch" \
- "${FILESDIR}/${P}"-gcc41.patch
+ [ $(gcc-major-version) -ge 3 ] && epatch "${FILESDIR}/${P}-gcc3.patch"
+ epatch "${FILESDIR}/libpng-1.2.5.patch"
use amd64 && epatch "${FILESDIR}/${P}-amd64.patch"
sed -i \
-e 's:-pedantic::' config/vars.mk \