Gentoo Archives: gentoo-commits

From: Ionen Wolkens <ionen@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: games-arcade/cdogs-sdl/files/, games-arcade/cdogs-sdl/
Date: Tue, 19 Oct 2021 02:29:11
Message-Id: 1634610416.1b0f8168efc7052faef7bf9a78fbf08ca3257e00.ionen@gentoo
1 commit: 1b0f8168efc7052faef7bf9a78fbf08ca3257e00
2 Author: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
3 AuthorDate: Tue Oct 19 01:16:45 2021 +0000
4 Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
5 CommitDate: Tue Oct 19 02:26:56 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1b0f8168
7
8 games-arcade/cdogs-sdl: add 1.1.1
9
10 * moved protobuf-python to BDEPEND with python-any-r1 (bug #768321)
11 * removed BUILD_EDITOR patch (upstreamed)
12 * EAPI-8 and small cleanups
13
14 Closes: https://bugs.gentoo.org/768321
15 Closes: https://bugs.gentoo.org/818862
16 Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>
17
18 games-arcade/cdogs-sdl/Manifest | 1 +
19 games-arcade/cdogs-sdl/cdogs-sdl-1.1.1.ebuild | 50 ++++++++++++++++++++++
20 .../cdogs-sdl/files/cdogs-sdl-1.1.1-cmake.patch | 14 ++++++
21 3 files changed, 65 insertions(+)
22
23 diff --git a/games-arcade/cdogs-sdl/Manifest b/games-arcade/cdogs-sdl/Manifest
24 index cc2ba05abf1..0c719c385c5 100644
25 --- a/games-arcade/cdogs-sdl/Manifest
26 +++ b/games-arcade/cdogs-sdl/Manifest
27 @@ -1 +1,2 @@
28 DIST cdogs-sdl-0.10.1.tar.gz 25035447 BLAKE2B 7f1ab1c210daaa44080cfca335cbcf0cd3ae069ef0638bd34c437e7b08833dfecfdf010ccdf9d5a4d3ede66cb75fd6258d3e8b7d907425fc0b73a792568ed205 SHA512 97bc23848536e98207afeaf74c172fe138dd0425dde6bb888b5c64f244b3c6ecea16245630628ab7aa4277da16c25c623574e8d123993bc9e840a3c26c1edce7
29 +DIST cdogs-sdl-1.1.1.tar.gz 35073687 BLAKE2B e4bcdbcafd281cfe127fc8b90bda479055042bf541ea7be7eaf2d0959e6d596565c8fca16bc703ca8263281d18372d89fa8ffa787592f3c01c0b048504df10fa SHA512 2d1357ba4a9892a7309d60b98aacf242b6d2b76f07f9f0a13fe0d97713b97507d1f163dfc63c1ac73c06b52590cda93bc212731bf201d5221ade8fa8b2e64598
30
31 diff --git a/games-arcade/cdogs-sdl/cdogs-sdl-1.1.1.ebuild b/games-arcade/cdogs-sdl/cdogs-sdl-1.1.1.ebuild
32 new file mode 100644
33 index 00000000000..58afa1925c7
34 --- /dev/null
35 +++ b/games-arcade/cdogs-sdl/cdogs-sdl-1.1.1.ebuild
36 @@ -0,0 +1,50 @@
37 +# Copyright 1999-2021 Gentoo Authors
38 +# Distributed under the terms of the GNU General Public License v2
39 +
40 +EAPI=8
41 +
42 +PYTHON_COMPAT=( python3_{8..10} )
43 +inherit cmake python-any-r1 xdg
44 +
45 +DESCRIPTION="Classic overhead run-and-gun game"
46 +HOMEPAGE="https://cxong.github.io/cdogs-sdl/"
47 +SRC_URI="https://github.com/cxong/cdogs-sdl/archive/${PV}.tar.gz -> ${P}.tar.gz"
48 +
49 +LICENSE="GPL-2+ BSD-2 CC0-1.0 CC-BY-3.0 CC-BY-SA-3.0 XMAME"
50 +SLOT="0"
51 +KEYWORDS="~amd64 ~x86"
52 +
53 +RDEPEND="
54 + media-libs/libsdl2[haptic,opengl]
55 + media-libs/sdl2-image[png]
56 + media-libs/sdl2-mixer[vorbis,wav]
57 + net-libs/enet:1.3="
58 +DEPEND="${RDEPEND}"
59 +BDEPEND="$(python_gen_any_dep 'dev-python/protobuf-python[${PYTHON_USEDEP}]')"
60 +
61 +PATCHES=(
62 + "${FILESDIR}"/${P}-cmake.patch
63 +)
64 +
65 +python_check_deps() {
66 + has_version -b "dev-python/protobuf-python[${PYTHON_USEDEP}]"
67 +}
68 +
69 +src_configure() {
70 + local mycmakeargs=(
71 + -DCDOGS_DATA_DIR="${EPREFIX}"/usr/share/${PN}/
72 + -DBUILD_EDITOR=OFF
73 + -DUSE_SHARED_ENET=ON
74 + )
75 +
76 + cmake_src_configure
77 +}
78 +
79 +src_install() {
80 + cmake_src_install
81 +
82 + dodoc doc/{AUTHORS,original_readme.txt}
83 +
84 + # CREDITS is used at runtime, rest is licenses or duplicates
85 + find "${ED}"/usr/share/${PN}/doc -type f ! -name CREDITS -delete || die
86 +}
87
88 diff --git a/games-arcade/cdogs-sdl/files/cdogs-sdl-1.1.1-cmake.patch b/games-arcade/cdogs-sdl/files/cdogs-sdl-1.1.1-cmake.patch
89 new file mode 100644
90 index 00000000000..92ce17bcbc3
91 --- /dev/null
92 +++ b/games-arcade/cdogs-sdl/files/cdogs-sdl-1.1.1-cmake.patch
93 @@ -0,0 +1,14 @@
94 +Remove -Werror and install data to CDOGS_DATA_DIR rather
95 +than directly under CMAKE_INSTALL_PREFIX.
96 +--- a/CMakeLists.txt
97 ++++ b/CMakeLists.txt
98 +@@ -128,3 +128,3 @@
99 + if(NOT BEOS AND NOT HAIKU)
100 +- add_definitions(-Winline -Werror)
101 ++ add_definitions(-Winline)
102 + set(EXTRA_LIBRARIES "m")
103 +@@ -195,3 +195,3 @@
104 + set(LIB_EXTENSION ".so")
105 +- set(DATA_INSTALL_DIR ".")
106 ++ set(DATA_INSTALL_DIR ${CDOGS_DATA_DIR})
107 + endif()