From 03c993729b80cc6835e8213ef80265b3b02e5305 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sat, 29 Feb 2020 11:39:27 +0000 Subject: [PATCH] games-roguelike/angband: tweak for gcc-10, bug #707770 Closes: https://bugs.gentoo.org/707770 Package-Manager: Portage-2.3.89, Repoman-2.3.20 Signed-off-by: Sergei Trofimovich --- games-roguelike/angband/angband-4.2.0.ebuild | 4 +++- .../angband/files/angband-4.2.0-gcc-10.patch | 22 +++++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 games-roguelike/angband/files/angband-4.2.0-gcc-10.patch diff --git a/games-roguelike/angband/angband-4.2.0.ebuild b/games-roguelike/angband/angband-4.2.0.ebuild index acb1f3d093ca..f9dfb300662f 100644 --- a/games-roguelike/angband/angband-4.2.0.ebuild +++ b/games-roguelike/angband/angband-4.2.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -48,6 +48,8 @@ RDEPEND="X? ( DEPEND="${RDEPEND}" BDEPEND="virtual/pkgconfig" +PATCHES=("${FILESDIR}"/${P}-gcc-10.patch) + src_prepare() { default diff --git a/games-roguelike/angband/files/angband-4.2.0-gcc-10.patch b/games-roguelike/angband/files/angband-4.2.0-gcc-10.patch new file mode 100644 index 000000000000..6aeb1f7a2047 --- /dev/null +++ b/games-roguelike/angband/files/angband-4.2.0-gcc-10.patch @@ -0,0 +1,22 @@ +https://bugs.gentoo.org/707770 + +--- a/src/mon-blows.h ++++ b/src/mon-blows.h +@@ -41,7 +41,7 @@ struct blow_method { + struct blow_method *next; + }; + +-struct blow_method *blow_methods; ++extern struct blow_method *blow_methods; + + /** + * Storage for context information for effect handlers called in +@@ -83,7 +83,7 @@ struct blow_effect { + struct blow_effect *next; + }; + +-struct blow_effect *blow_effects; ++extern struct blow_effect *blow_effects; + + /* Functions */ + int blow_index(const char *name); -- 2.26.2