diff options
author | Azamat H. Hackimov <azamat.hackimov@gmail.com> | 2020-06-08 20:28:32 +0300 |
---|---|---|
committer | James Le Cuirot <chewi@gentoo.org> | 2020-06-08 22:54:19 +0100 |
commit | 604c163d3a85f4de6a35bda75e77518060c3e7c8 (patch) | |
tree | 1f4abacc291f4b81acd575f3a075219a3cd02274 /games-puzzle | |
parent | x11-misc/xkeyboard-config: Version bump to 2.30 (diff) | |
download | gentoo-604c163d3a85f4de6a35bda75e77518060c3e7c8.tar.gz gentoo-604c163d3a85f4de6a35bda75e77518060c3e7c8.tar.bz2 gentoo-604c163d3a85f4de6a35bda75e77518060c3e7c8.zip |
games-puzzle/freesweep: update to 1.0.1
Update to new version, fix gcc 10 compilation (#706910, patch taken from
https://github.com/rwestlund/freesweep/pull/8).
Closes: https://bugs.gentoo.org/706910
Package-Manager: Portage-2.3.99, Repoman-2.3.22
Signed-off-by: Azamat H. Hackimov <azamat.hackimov@gmail.com>
Signed-off-by: James Le Cuirot <chewi@gentoo.org>
Diffstat (limited to 'games-puzzle')
-rw-r--r-- | games-puzzle/freesweep/Manifest | 1 | ||||
-rw-r--r-- | games-puzzle/freesweep/files/freesweep-1.0.1-gcc10.patch | 39 | ||||
-rw-r--r-- | games-puzzle/freesweep/freesweep-1.0.1.ebuild | 31 |
3 files changed, 71 insertions, 0 deletions
diff --git a/games-puzzle/freesweep/Manifest b/games-puzzle/freesweep/Manifest index f9f29ef41123..f13ddf87f7f9 100644 --- a/games-puzzle/freesweep/Manifest +++ b/games-puzzle/freesweep/Manifest @@ -1 +1,2 @@ DIST freesweep-0.92.tar.gz 87353 BLAKE2B 8775a5c135e5a7faba00af2e2fd279c619a8092ad905c8dfa3d3ac7755d0b6337cb39f4b93e0c4bb1e905a87770e946cb728256bc5a2897794802424fa5ebdc2 SHA512 9f7f33ba5fab62d1ea3a6a57b9a60323281c91255218afb51251c4e20500c123769f003ae1a3622205be34fa7cfe11b691e58ad8787782da4d0a7045d4f41122 +DIST freesweep-1.0.1.tar.gz 93966 BLAKE2B 8eab63930e41067e2e5626a4504bef00db58bfde54a43c4512bed2e8ae186d165b5b15acf8c1074a8b02e1d63876fb4e36b8c78f181c7d86d055976a15b8ec83 SHA512 8270c77940225c8ebf0912ac896eaaaabd81775a82877650f3b9c2e0cf3b6a296b73f02ebc26e8fe526fc56f3807d9a2809f46e44b3d8507f011f9cf2c794099 diff --git a/games-puzzle/freesweep/files/freesweep-1.0.1-gcc10.patch b/games-puzzle/freesweep/files/freesweep-1.0.1-gcc10.patch new file mode 100644 index 000000000000..4288c8b26a2c --- /dev/null +++ b/games-puzzle/freesweep/files/freesweep-1.0.1-gcc10.patch @@ -0,0 +1,39 @@ +From a86245df4f3ff276a393f799d737d28a5cb0a5a8 Mon Sep 17 00:00:00 2001 +From: Reiner Herrmann <reiner@reiner-h.de> +Date: Thu, 23 Apr 2020 00:46:58 +0200 +Subject: [PATCH] Fix build with GCC 10 + +mark variable declaration in sweep.h as extern, as otherwise +linker would complain about multiple definitions. +keep actual declaration in a C file. +--- + main.c | 2 ++ + sweep.h.in | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/main.c b/main.c +index 6411dcb..8d5cbe7 100644 +--- a/main.c ++++ b/main.c +@@ -10,6 +10,8 @@ + + #include "sweep.h" + ++DrawChars CharSet; ++ + int main(int argc, char** argv) + { + GameStats* Game; +diff --git a/sweep.h.in b/sweep.h.in +index f30c133..7f398de 100644 +--- a/sweep.h.in ++++ b/sweep.h.in +@@ -246,7 +246,7 @@ struct FileBuf + FILE* DebugLog; + #endif /* DEBUG_LOG */ + +-DrawChars CharSet; ++extern DrawChars CharSet; + + /* These are the functions defined in files.c */ + int SourceHomeFile(GameStats* Game); diff --git a/games-puzzle/freesweep/freesweep-1.0.1.ebuild b/games-puzzle/freesweep/freesweep-1.0.1.ebuild new file mode 100644 index 000000000000..3a27c3f4f0b9 --- /dev/null +++ b/games-puzzle/freesweep/freesweep-1.0.1.ebuild @@ -0,0 +1,31 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +inherit toolchain-funcs + +DESCRIPTION="Console Minesweeper" +HOMEPAGE="https://github.com/rwestlund/freesweep" +SRC_URI="https://github.com/rwestlund/freesweep/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86 ~ppc-macos" + +RDEPEND="sys-libs/ncurses:0=" +DEPEND="${RDEPEND}" +BDEPEND="virtual/pkgconfig" + +PATCHES=( + "${FILESDIR}/${P}-gcc10.patch" +) + +src_compile() { + emake LIBS="$( $(tc-getPKG_CONFIG) --libs ncurses)" +} + +src_install() { + dobin freesweep + einstalldocs + doman freesweep.6 +} |