Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: games-action/btanks/, games-action/btanks/files/
Date: Sun, 30 Jul 2017 09:10:17
Message-Id: 1501405790.ddc1a4cfd09f5429575c3eba483995b22907d9ef.soap@gentoo
1 commit: ddc1a4cfd09f5429575c3eba483995b22907d9ef
2 Author: Peter Levine <plevine457 <AT> gmail <DOT> com>
3 AuthorDate: Mon Jul 24 04:26:42 2017 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Sun Jul 30 09:09:50 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ddc1a4cf
7
8 games-action/btanks: Fix building with -Werror=terminate in GCC-6
9
10 Bug: https://bugs.gentoo.org/show_bug.cgi?id=609692
11 Package-Manager: Portage-2.3.6, Repoman-2.3.2
12 Closes: https://github.com/gentoo/gentoo/pull/5190
13
14 games-action/btanks/btanks-0.9.8083.ebuild | 5 ++--
15 .../btanks/files/btanks-0.9.8083-gcc6.patch | 34 ++++++++++++++++++++++
16 2 files changed, 37 insertions(+), 2 deletions(-)
17
18 diff --git a/games-action/btanks/btanks-0.9.8083.ebuild b/games-action/btanks/btanks-0.9.8083.ebuild
19 index c080022faa9..9da95ffb8f3 100644
20 --- a/games-action/btanks/btanks-0.9.8083.ebuild
21 +++ b/games-action/btanks/btanks-0.9.8083.ebuild
22 @@ -1,4 +1,4 @@
23 -# Copyright 1999-2015 Gentoo Foundation
24 +# Copyright 1999-2017 Gentoo Foundation
25 # Distributed under the terms of the GNU General Public License v2
26
27 EAPI=5
28 @@ -28,7 +28,8 @@ src_prepare() {
29 rm -rf sdlx/gfx
30 epatch "${FILESDIR}"/${P}-scons-blows.patch \
31 "${FILESDIR}"/${P}-gcc46.patch \
32 - "${FILESDIR}"/${P}-gcc47.patch
33 + "${FILESDIR}"/${P}-gcc47.patch \
34 + "${FILESDIR}"/${P}-gcc6.patch
35 }
36
37 src_compile() {
38
39 diff --git a/games-action/btanks/files/btanks-0.9.8083-gcc6.patch b/games-action/btanks/files/btanks-0.9.8083-gcc6.patch
40 new file mode 100644
41 index 00000000000..5f11379d805
42 --- /dev/null
43 +++ b/games-action/btanks/files/btanks-0.9.8083-gcc6.patch
44 @@ -0,0 +1,34 @@
45 +Bug: https://bugs.gentoo.org/609692
46 +
47 +--- a/mrt/timespy.cpp
48 ++++ b/mrt/timespy.cpp
49 +@@ -43,7 +43,7 @@
50 + throw_io(("gettimeofday"));
51 + }
52 +
53 +-TimeSpy::~TimeSpy() {
54 ++TimeSpy::~TimeSpy() DTOR_NOEXCEPT {
55 + struct timeval now;
56 + if (gettimeofday(&now, NULL) == -1)
57 + throw_io(("gettimeofday"));
58 +--- a/mrt/timespy.h
59 ++++ b/mrt/timespy.h
60 +@@ -37,11 +37,17 @@
61 + #include "fmt.h"
62 + #include "export_mrt.h"
63 +
64 ++#if __cplusplus >= 201103L
65 ++#define DTOR_NOEXCEPT noexcept(false)
66 ++#else
67 ++#define DTOR_NOEXCEPT
68 ++#endif
69 ++
70 + namespace mrt {
71 + class MRTAPI TimeSpy {
72 + public:
73 + TimeSpy(const std::string &message);
74 +- ~TimeSpy();
75 ++ ~TimeSpy() DTOR_NOEXCEPT;
76 + private:
77 + TimeSpy(const TimeSpy&);
78 + const TimeSpy& operator=(const TimeSpy&);