summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIonen Wolkens <ionen@gentoo.org>2022-11-07 19:58:19 -0500
committerIonen Wolkens <ionen@gentoo.org>2022-11-08 00:36:54 -0500
commit92561523ab995f58eec490f9da3962ad661b9e2f (patch)
tree61ad7dfb0feeb71d1b22fd4abd1d3aa6daef0b26 /games-rpg
parentgames-rpg/freedink: add savannah upstream metadata (diff)
downloadgentoo-92561523ab995f58eec490f9da3962ad661b9e2f.tar.gz
gentoo-92561523ab995f58eec490f9da3962ad661b9e2f.tar.bz2
gentoo-92561523ab995f58eec490f9da3962ad661b9e2f.zip
games-rpg/freedink: add 109.6
Now uses SDL2. ebuild changes: * EAPI6->8 * fix licenses wrt bug #880183 (minus public-domain, binreloc.c is not in this version) * update HOMEPAGE, old domain seems dead * tentatively drop -O? -> -O0 replace-flags, many changes including using C++ and hopefully is not relevant anymore (or at least, I can load save games even with -O3) -> also drop filter-flags, it had no arguments and was no-op (likely was meant to be strip-flags) * change windres workaround to not need a patch (note it gives a misleading error about lacking Ogg support, but if look at debug output it successfully finds Ogg differently) Closes: https://bugs.gentoo.org/880183 Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
Diffstat (limited to 'games-rpg')
-rw-r--r--games-rpg/freedink/Manifest1
-rw-r--r--games-rpg/freedink/files/freedink-109.6-odr.patch14
-rw-r--r--games-rpg/freedink/files/freedink-109.6-sdl.patch20
-rw-r--r--games-rpg/freedink/freedink-109.6.ebuild50
4 files changed, 85 insertions, 0 deletions
diff --git a/games-rpg/freedink/Manifest b/games-rpg/freedink/Manifest
index 8dda84256cf9..56d7ac3ac4e8 100644
--- a/games-rpg/freedink/Manifest
+++ b/games-rpg/freedink/Manifest
@@ -1 +1,2 @@
DIST freedink-108.4.tar.gz 1897701 BLAKE2B b26129f3e5d17895a08cac9564973e31d6e8e2458ac9a2ed4b00f53cd1b8004073022a8e3f4cf8ded2e44cc4bb73909f021a7c960d219e78aec47b4c4ce7c18e SHA512 1496b6a7826bf694a2919add22a8b4b08a4967d8a7fdebf2d599bd99c7a7ce67de6c2b11124423c7aa1f0feb2e7c03ce1cf00252070182936e7481791dafee61
+DIST freedink-109.6.tar.gz 1587238 BLAKE2B dc7892114af6968170ed35771d85fd4d8bef969ee2df9b45b315b8b70f50058f5713e22c657ea48e8297cd15c2401e1749c1660bd59140495eba9bcaaf6bf1fc SHA512 9de4155e65c1af58166e30f3f642fed2111eeff2cfccedcd51ea7715e91795d9c9f89d4fa30a801e9a998b7d734682b7d2588ef1ebaba464764c3c3156b6a7ad
diff --git a/games-rpg/freedink/files/freedink-109.6-odr.patch b/games-rpg/freedink/files/freedink-109.6-odr.patch
new file mode 100644
index 000000000000..560c3ddc6537
--- /dev/null
+++ b/games-rpg/freedink/files/freedink-109.6-odr.patch
@@ -0,0 +1,14 @@
+Only ever used as struct FF_Handle *, not seeing why this void is here.
+error: 'FastFileOpen' violates the C++ One Definition Rule [-Werror=odr]
+--- a/src/fastfile.cpp
++++ b/src/fastfile.cpp
+@@ -217,3 +217,3 @@
+
+-void *
++struct FF_Handle *
+ FastFileOpen(char *name)
+@@ -254,3 +254,3 @@
+ i->len = next_off - i->off;
+- return (void*)i;
++ return i;
+ }
diff --git a/games-rpg/freedink/files/freedink-109.6-sdl.patch b/games-rpg/freedink/files/freedink-109.6-sdl.patch
new file mode 100644
index 000000000000..f00735d7b377
--- /dev/null
+++ b/games-rpg/freedink/files/freedink-109.6-sdl.patch
@@ -0,0 +1,20 @@
+For newer sdl2 and sdl2-ttf
+https://lists.gnu.org/archive/html/bug-freedink/2019-08/msg00000.html
+https://lists.gnu.org/archive/html/bug-freedink/2022-07/msg00001.html
+--- a/src/gfx_fonts.cpp
++++ b/src/gfx_fonts.cpp
+@@ -295,6 +295,6 @@
+ {
+- char *familyname = TTF_FontFaceFamilyName(font);
++ const char *familyname = TTF_FontFaceFamilyName(font);
+ if(familyname)
+ log_info("The family name of the face in the font is: %s", familyname);
+- char *stylename = TTF_FontFaceStyleName(font);
++ const char *stylename = TTF_FontFaceStyleName(font);
+ if(stylename)
+--- a/src/input.cpp
++++ b/src/input.cpp
+@@ -93,3 +93,2 @@
+ // fake mouse events often are de-centered
+- SDL_SetHint(SDL_HINT_ANDROID_SEPARATE_MOUSE_AND_TOUCH, "0");
+
diff --git a/games-rpg/freedink/freedink-109.6.ebuild b/games-rpg/freedink/freedink-109.6.ebuild
new file mode 100644
index 000000000000..bec7622f80e2
--- /dev/null
+++ b/games-rpg/freedink/freedink-109.6.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit xdg
+
+DESCRIPTION="Dink Smallwood is an adventure/role-playing game, similar to Zelda (2D top view)"
+HOMEPAGE="https://www.gnu.org/s/freedink/"
+SRC_URI="mirror://gnu/freedink/${P}.tar.gz"
+
+LICENSE="GPL-3+ LGPL-2.1+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+COMMON_DEPEND="
+ media-libs/fontconfig
+ media-libs/libsdl2[joystick,sound,video]
+ media-libs/sdl2-gfx
+ media-libs/sdl2-image
+ media-libs/sdl2-mixer[midi,vorbis,wav]
+ media-libs/sdl2-ttf"
+RDEPEND="
+ ${COMMON_DEPEND}
+ games-rpg/freedink-data"
+DEPEND="
+ ${COMMON_DEPEND}
+ media-libs/glm"
+BDEPEND="
+ sys-devel/gettext
+ virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-odr.patch
+ "${FILESDIR}"/${P}-sdl.patch
+)
+
+src_configure() {
+ local econfargs=(
+ # TODO? Needs unpackaged cxxtest, but that package (currently) seem
+ # dead and may not be worth adding just for testing this.
+ --disable-tests
+
+ # Fails if finds a windres executable
+ ac_cv_prog_WINDRES=
+ ac_cv_prog_ac_ct_WINDRES=
+ )
+
+ econf "${econfargs[@]}"
+}