* [gentoo-commits] repo/gentoo:master commit in: games-emulation/hatari/files/, games-emulation/hatari/
@ 2018-07-13 9:27 Tony Vroon
0 siblings, 0 replies; 4+ messages in thread
From: Tony Vroon @ 2018-07-13 9:27 UTC (permalink / raw
To: gentoo-commits
commit: 81314cd16c5799e482ba4c20d3f5f4dee3136e88
Author: Azamat H. Hackimov <azamat.hackimov <AT> gmail <DOT> com>
AuthorDate: Wed Jul 11 22:11:23 2018 +0000
Commit: Tony Vroon <chainsaw <AT> gentoo <DOT> org>
CommitDate: Fri Jul 13 09:27:11 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=81314cd1
games-emulation/hatari: remove old
Removed old games.eclass based version
Package-Manager: Portage-2.3.40, Repoman-2.3.9
games-emulation/hatari/Manifest | 1 -
.../hatari/files/hatari-1.8.0-gentoo-docdir.patch | 13 ---
.../hatari/files/hatari-1.8.0-gentoo.patch | 112 ---------------------
games-emulation/hatari/hatari-1.8.0.ebuild | 89 ----------------
4 files changed, 215 deletions(-)
diff --git a/games-emulation/hatari/Manifest b/games-emulation/hatari/Manifest
index 8f2de08f387..e061a3037e6 100644
--- a/games-emulation/hatari/Manifest
+++ b/games-emulation/hatari/Manifest
@@ -1,2 +1 @@
-DIST hatari-1.8.0.tar.bz2 1985358 BLAKE2B 12fc000dd04c0f0dcead0b6713837a0d4c02df5ecdab9c2d4d2d91bd4cf6f8657acf2d97649a5704b646fae4fefe0626300e297b9e8698e7b8b72854d37b7097 SHA512 498a6636eef78e85a4715e9df169d928ce97c0548145a95b41aa3aae28817b8e843de1d1390893863be05e4e9981c89236571ab2eb9239faad23b711542e4fa0
DIST hatari-2.1.0.tar.bz2 4072778 BLAKE2B 934ab28e799d0d13c26c291005513511367eb2ddbeda0f9756c19f10fa9e6bb8e10451057fa7e0b49a30e3f562eb5f327057d324b2a92e09b1115f63132dca97 SHA512 d1fbf6e60e2df2c43d070bee6a9c1dc93c36a8ea7f75bbf2a67790840952661cee136ebccd6b2ed523ef9b7b56391e058384f2e3f46acb609bb362cac05b9753
diff --git a/games-emulation/hatari/files/hatari-1.8.0-gentoo-docdir.patch b/games-emulation/hatari/files/hatari-1.8.0-gentoo-docdir.patch
deleted file mode 100644
index 715fb189143..00000000000
--- a/games-emulation/hatari/files/hatari-1.8.0-gentoo-docdir.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- hatari-1.6.1/python-ui/uihelpers.py
-+++ hatari-1.6.1/python-ui/uihelpers.py
-@@ -97,9 +97,7 @@
- # first try whether there are local Hatari docs in standard place
- # for this Hatari/UI version
- sep = os.sep
-- path = self.get_binary_path("hatari")
-- path = sep.join(path.split(sep)[:-2]) # remove "bin/hatari"
-- path = path + sep + "share" + sep + "doc" + sep + "hatari" + sep
-+ path = "@DOCDIR@"
- if os.path.exists(path + "manual.html"):
- return path
- # if not, point to latest Hatari HG version docs
diff --git a/games-emulation/hatari/files/hatari-1.8.0-gentoo.patch b/games-emulation/hatari/files/hatari-1.8.0-gentoo.patch
deleted file mode 100644
index 4f10d6d9e3c..00000000000
--- a/games-emulation/hatari/files/hatari-1.8.0-gentoo.patch
+++ /dev/null
@@ -1,112 +0,0 @@
---- hatari-1.4.0.orig/src/paths.c
-+++ hatari-1.4.0/src/paths.c
-@@ -109,71 +109,6 @@
- free(pTmpName);
- }
-
--
--/**
-- * Locate the directory where the hatari executable resides
-- */
--static char *Paths_InitExecDir(const char *argv0)
--{
-- char *psExecDir; /* Path string where the hatari executable can be found */
--
-- /* Allocate memory for storing the path string of the executable */
-- psExecDir = malloc(FILENAME_MAX);
-- if (!psExecDir)
-- {
-- fprintf(stderr, "Out of memory (Paths_Init)\n");
-- exit(-1);
-- }
--
-- /* Determine the bindir...
-- * Start with empty string, then try to use OS specific functions,
-- * and finally analyze the PATH variable if it has not been found yet. */
-- psExecDir[0] = '\0';
--
--#if defined(__linux__)
-- {
-- int i;
-- /* On Linux, we can analyze the symlink /proc/self/exe */
-- i = readlink("/proc/self/exe", psExecDir, FILENAME_MAX);
-- if (i > 0)
-- {
-- char *p;
-- psExecDir[i] = '\0';
-- p = strrchr(psExecDir, '/'); /* Search last slash */
-- if (p)
-- *p = 0; /* Strip file name from path */
-- }
-- }
--//#elif defined(WIN32) || defined(__CEGCC__)
--// /* On Windows we can use GetModuleFileName for getting the exe path */
--// GetModuleFileName(NULL, psExecDir, FILENAME_MAX);
--#endif
--
-- /* If we do not have the execdir yet, analyze argv[0] and the PATH: */
-- if (psExecDir[0] == 0)
-- {
-- if (strchr(argv0, PATHSEP) == 0)
-- {
-- /* No separator in argv[0], we have to explore PATH... */
-- Paths_GetExecDirFromPATH(argv0, psExecDir, FILENAME_MAX);
-- }
-- else
-- {
-- /* There was a path separator in argv[0], so let's assume a
-- * relative or absolute path to the current directory in argv[0] */
-- char *p;
-- strncpy(psExecDir, argv0, FILENAME_MAX);
-- psExecDir[FILENAME_MAX-1] = 0;
-- p = strrchr(psExecDir, PATHSEP); /* Search last slash */
-- if (p)
-- *p = 0; /* Strip file name from path */
-- }
-- }
--
-- return psExecDir;
--}
--
--
- /**
- * Initialize the users home directory string
- * and Hatari's home directory (~/.hatari)
-@@ -226,8 +161,6 @@
- */
- void Paths_Init(const char *argv0)
- {
-- char *psExecDir; /* Path string where the hatari executable can be found */
--
- /* Init working directory string */
- if (getcwd(sWorkingDir, FILENAME_MAX) == NULL)
- {
-@@ -238,27 +171,11 @@
- /* Init the user's home directory string */
- Paths_InitHomeDirs();
-
-- /* Get the directory where the executable resides */
-- psExecDir = Paths_InitExecDir(argv0);
--
-- /* Now create the datadir path name from the bindir path name: */
-- if (psExecDir && strlen(psExecDir) > 0)
-- {
-- snprintf(sDataDir, sizeof(sDataDir), "%s%c%s",
-- psExecDir, PATHSEP, BIN2DATADIR);
-- }
-- else
-- {
-- /* bindir could not be determined, let's assume datadir is relative
-- * to current working directory... */
-- strcpy(sDataDir, BIN2DATADIR);
-- }
-+ strcpy(sDataDir, BIN2DATADIR);
-
- /* And finally make a proper absolute path out of datadir: */
- File_MakeAbsoluteName(sDataDir);
-
-- free(psExecDir);
--
- /* fprintf(stderr, " WorkingDir = %s\n DataDir = %s\n UserHomeDir = %s\n HatariHomeDir = %s\n",
- sWorkingDir, sDataDir, sUserHomeDir, sHatariHomeDir); */
- }
diff --git a/games-emulation/hatari/hatari-1.8.0.ebuild b/games-emulation/hatari/hatari-1.8.0.ebuild
deleted file mode 100644
index 0ec9601e183..00000000000
--- a/games-emulation/hatari/hatari-1.8.0.ebuild
+++ /dev/null
@@ -1,89 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-PYTHON_COMPAT=( python2_7 )
-inherit eutils toolchain-funcs cmake-utils python-single-r1 games
-
-DESCRIPTION="Atari ST emulator"
-HOMEPAGE="http://hatari.tuxfamily.org/"
-SRC_URI="http://download.tuxfamily.org/hatari/${PV}/${P}.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE=""
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-RDEPEND="${PYTHON_DEPS}
- media-libs/libsdl[X,sound,video]
- sys-libs/readline:0
- media-libs/libpng:0
- sys-libs/zlib"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
-RDEPEND="${RDEPEND}
- dev-python/pygtk[${PYTHON_USEDEP}]
- games-emulation/emutos"
-
-PATCHES=(
- "${FILESDIR}"/${P}-gentoo.patch
- "${FILESDIR}"/${P}-gentoo-docdir.patch
-)
-
-pkg_setup() {
- games_pkg_setup
- python-single-r1_pkg_setup
-}
-
-src_prepare() {
- cmake-utils_src_prepare
-
- # build with newer zlib (bug #387829)
- sed -i -e '1i#define OF(x) x' src/includes/unzip.h || die
- sed -i -e '/Encoding/d' ./python-ui/hatariui.desktop || die
- sed -i -e "s/python/${EPYTHON}/" tools/atari-hd-image.sh || die
- sed -i \
- -e "s%conf=.*$%conf=\"${GAMES_SYSCONFDIR}\"%" \
- -e "s%path=.*$%path=\"${GAMES_DATADIR}/${PN}/hatariui\"%" \
- python-ui/hatariui || die
- sed -i -e "s#@DOCDIR@#/usr/share/doc/${PF}/html/#" python-ui/uihelpers.py || die
- rm -f doc/CMakeLists.txt
-}
-
-src_configure() {
- mycmakeargs=(
- "-DCMAKE_VERBOSE_MAKEFILE=TRUE"
- "-DCMAKE_BUILD_TYPE:STRING=Release"
- "-DDATADIR=${GAMES_DATADIR}/${PN}"
- "-DBIN2DATADIR=${GAMES_DATADIR}/${PN}"
- "-DBINDIR=${GAMES_BINDIR}"
- "-DICONDIR=/usr/share/pixmaps"
- "-DDESKTOPDIR=/usr/share/applications"
- "-DMANDIR=/usr/share/man/man1"
- "-DDOCDIR=/usr/share/doc/${PF}"
- )
- cmake-utils_src_configure
-}
-
-src_install() {
- DOCS="readme.txt doc/*.txt" cmake-utils_src_install
- dohtml -r doc/
- python_fix_shebang "${ED%/}"/usr/share/games/hatari/{hatariui,hconsole}/
- prepgamesdirs
-}
-
-pkg_postinst() {
- games_pkg_postinst
- echo
- elog "You need a TOS ROM to run hatari. EmuTOS, a free TOS implementation,"
- elog "has been installed in $(games_get_libdir) with a .img extension (there"
- elog "are several from which to choose)."
- elog
- elog "Another option is to go to http://www.atari.st/ and get a real TOS:"
- elog " http://www.atari.st/"
- elog
- elog "The first time you run hatari, you should configure it to find the"
- elog "TOS you prefer to use. Be sure to save your settings."
- echo
-}
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: games-emulation/hatari/files/, games-emulation/hatari/
@ 2019-11-10 21:39 James Le Cuirot
0 siblings, 0 replies; 4+ messages in thread
From: James Le Cuirot @ 2019-11-10 21:39 UTC (permalink / raw
To: gentoo-commits
commit: 95918849608a85cb055a0736754981ff9adf5d1a
Author: James Le Cuirot <chewi <AT> gentoo <DOT> org>
AuthorDate: Sun Nov 10 21:37:12 2019 +0000
Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org>
CommitDate: Sun Nov 10 21:39:27 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=95918849
games-emulation/hatari: Bump to 2.2.1, EAPI 7, lots of improvements
It turns out most of the dependencies are optional.
Closes: https://bugs.gentoo.org/689538
Package-Manager: Portage-2.3.79, Repoman-2.3.17
Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>
games-emulation/hatari/Manifest | 1 +
.../hatari/files/hatari-2.2.1-default-rom.patch | 16 +++++
.../hatari/files/hatari-2.2.1-joystick.patch | 59 ++++++++++++++++
games-emulation/hatari/hatari-2.2.1.ebuild | 80 ++++++++++++++++++++++
games-emulation/hatari/metadata.xml | 3 +
5 files changed, 159 insertions(+)
diff --git a/games-emulation/hatari/Manifest b/games-emulation/hatari/Manifest
index e061a3037e6..2d2d4017ca7 100644
--- a/games-emulation/hatari/Manifest
+++ b/games-emulation/hatari/Manifest
@@ -1 +1,2 @@
DIST hatari-2.1.0.tar.bz2 4072778 BLAKE2B 934ab28e799d0d13c26c291005513511367eb2ddbeda0f9756c19f10fa9e6bb8e10451057fa7e0b49a30e3f562eb5f327057d324b2a92e09b1115f63132dca97 SHA512 d1fbf6e60e2df2c43d070bee6a9c1dc93c36a8ea7f75bbf2a67790840952661cee136ebccd6b2ed523ef9b7b56391e058384f2e3f46acb609bb362cac05b9753
+DIST hatari-2.2.1.tar.bz2 4162798 BLAKE2B 51938a649957779652b0debf7f867b2abe2d54fd3bb31086542f9f5970d01a120455e4381a9cb173724fbc7c45359d4009377bfe99038b338142fa5b82723533 SHA512 0e4c148a355a53c9cf79bdd28e5d7bb5f3389c780576017c6ebe2b69465d67522f373945f0e51681120ece24f5f08442265515486d2d7df7a02d9cd94cc44f1e
diff --git a/games-emulation/hatari/files/hatari-2.2.1-default-rom.patch b/games-emulation/hatari/files/hatari-2.2.1-default-rom.patch
new file mode 100644
index 00000000000..c42f67f733c
--- /dev/null
+++ b/games-emulation/hatari/files/hatari-2.2.1-default-rom.patch
@@ -0,0 +1,16 @@
+Use etos512k.img from the emutos package rather than tos.img.
+
+diff -Naur a/src/configuration.c b/src/configuration.c
+--- a/src/configuration.c 2019-02-08 08:30:11.000000000 +0000
++++ b/src/configuration.c 2019-11-10 21:19:31.712605716 +0000
+@@ -841,8 +841,8 @@
+ ConfigureParams.Sound.YmVolumeMixing = YM_TABLE_MIXING;
+
+ /* Set defaults for Rom */
+- sprintf(ConfigureParams.Rom.szTosImageFileName, "%s%ctos.img",
+- Paths_GetDataDir(), PATHSEP);
++ sprintf(ConfigureParams.Rom.szTosImageFileName, "%s%c..%cemutos%cetos512k.img",
++ Paths_GetDataDir(), PATHSEP, PATHSEP, PATHSEP);
+ ConfigureParams.Rom.bPatchTos = true;
+ strcpy(ConfigureParams.Rom.szCartridgeImageFileName, "");
+
diff --git a/games-emulation/hatari/files/hatari-2.2.1-joystick.patch b/games-emulation/hatari/files/hatari-2.2.1-joystick.patch
new file mode 100644
index 00000000000..193bb7206c3
--- /dev/null
+++ b/games-emulation/hatari/files/hatari-2.2.1-joystick.patch
@@ -0,0 +1,59 @@
+https://bugs.gentoo.org/689538
+
+diff -ruN hatari-2.1.0.old/src/gui-sdl/sdlgui.c hatari-2.1.0/src/gui-sdl/sdlgui.c
+--- hatari-2.1.0.old/src/gui-sdl/sdlgui.c 2018-02-07 18:33:56.000000000 +0000
++++ hatari-2.1.0/src/gui-sdl/sdlgui.c 2019-07-08 23:55:50.481270799 +0100
+@@ -1329,12 +1329,28 @@
+ }
+ break;
+
++ case SDL_JOYHATMOTION:
++ if (sdlEvent.jhat.value & SDL_HAT_LEFT)
++ retbutton = SDLGui_HandleShortcut(dlg, SG_SHORTCUT_LEFT);
++ else if (sdlEvent.jhat.value & SDL_HAT_RIGHT)
++ retbutton = SDLGui_HandleShortcut(dlg, SG_SHORTCUT_RIGHT);
++ if (sdlEvent.jhat.value & SDL_HAT_UP)
++ {
++ SDLGui_RemoveFocus(dlg, focused);
++ focused = SDLGui_FocusNext(dlg, focused, -1);
++ }
++ else if (sdlEvent.jhat.value & SDL_HAT_DOWN)
++ {
++ SDLGui_RemoveFocus(dlg, focused);
++ focused = SDLGui_FocusNext(dlg, focused, +1);
++ }
++ break;
++
+ case SDL_JOYBUTTONDOWN:
+ retbutton = SDLGui_HandleSelection(dlg, focused, focused);
+ break;
+
+ case SDL_JOYBALLMOTION:
+- case SDL_JOYHATMOTION:
+ case SDL_MOUSEMOTION:
+ break;
+
+diff -ruN hatari-2.1.0.old/src/joy.c hatari-2.1.0/src/joy.c
+--- hatari-2.1.0.old/src/joy.c 2018-02-07 18:33:56.000000000 +0000
++++ hatari-2.1.0/src/joy.c 2019-07-09 14:46:36.502410790 +0100
+@@ -199,9 +199,20 @@
+ */
+ static bool Joy_ReadJoystick(int nSdlJoyID, JOYREADING *pJoyReading)
+ {
++ unsigned hat = SDL_JoystickGetHat(sdlJoystick[nSdlJoyID], 0);
++
+ /* Joystick is OK, read position from the configured joystick axis */
+ pJoyReading->XPos = SDL_JoystickGetAxis(sdlJoystick[nSdlJoyID], pJoyReading->XAxisID);
+ pJoyReading->YPos = SDL_JoystickGetAxis(sdlJoystick[nSdlJoyID], pJoyReading->YAxisID);
++ /* Similarly to other emulators that support hats, override axis readings with hats */
++ if (hat & SDL_HAT_LEFT)
++ pJoyReading->XPos = -32768;
++ if (hat & SDL_HAT_RIGHT)
++ pJoyReading->XPos = 32767;
++ if (hat & SDL_HAT_UP)
++ pJoyReading->YPos = -32768;
++ if (hat & SDL_HAT_DOWN)
++ pJoyReading->YPos = 32767;
+ /* Sets bit #0 if button #1 is pressed: */
+ pJoyReading->Buttons = SDL_JoystickGetButton(sdlJoystick[nSdlJoyID], 0);
+ /* Sets bit #1 if button #2 is pressed: */
diff --git a/games-emulation/hatari/hatari-2.2.1.ebuild b/games-emulation/hatari/hatari-2.2.1.ebuild
new file mode 100644
index 00000000000..a8f84107c83
--- /dev/null
+++ b/games-emulation/hatari/hatari-2.2.1.ebuild
@@ -0,0 +1,80 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python{2_7,3_{6,7}} )
+inherit cmake-utils python-single-r1 xdg
+
+DESCRIPTION="Atari ST emulator"
+HOMEPAGE="https://hatari.tuxfamily.org/"
+SRC_URI="https://download.tuxfamily.org/hatari/${PV}/${P}.tar.bz2"
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="capsimage microphone png portmidi readline +sdl2 udev zlib"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+DEPEND="
+ ${PYTHON_DEPS}
+ capsimage? ( >=dev-libs/spsdeclib-5.1-r1 )
+ microphone? ( media-libs/portaudio )
+ png? ( media-libs/libpng:0= )
+ portmidi? ( media-libs/portmidi )
+ readline? ( sys-libs/readline:0= )
+ sdl2? ( media-libs/libsdl2[sound,video,X] )
+ !sdl2? ( media-libs/libsdl[sound,video,X] )
+ udev? ( virtual/udev )
+ zlib? ( sys-libs/zlib )
+"
+
+RDEPEND="
+ ${DEPEND}
+ dev-python/pygobject:3[${PYTHON_USEDEP}]
+ >=games-emulation/emutos-0.9.9.1
+"
+
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-2.2.1-default-rom.patch
+ "${FILESDIR}"/${PN}-2.2.1-joystick.patch
+)
+
+DOCS=(
+ readme.txt
+ doc/{changelog,coding,scsi-driver,thanks,video-recording}.txt
+)
+
+src_prepare() {
+ xdg_environment_reset
+ cmake-utils_src_prepare
+
+ sed -i "s/\.1\.gz\b/.1/g;T;s/gzip[^\$]*/cat /g" {*/,}*/CMakeLists.txt || die
+ sed -i "s:\"doc\" + sep + \"hatari\":\"doc/${PF}\":" python-ui/uihelpers.py || die
+ sed -i "s/python/${EPYTHON}/" tools/atari-hd-image.sh || die
+
+ # Use emutos package rather than bundled ROM.
+ rm src/tos.img || die
+}
+
+src_configure() {
+ mycmakeargs=(
+ -DBUILD_SHARED_LIBS=OFF
+ -DDOCDIR="${EPREFIX}"/usr/share/doc/${PF}
+ -DENABLE_SDL2=$(usex sdl2)
+ -DCMAKE_DISABLE_FIND_PACKAGE_CapsImage=$(usex !capsimage)
+ -DCMAKE_DISABLE_FIND_PACKAGE_PortAudio=$(usex !microphone)
+ -DCMAKE_DISABLE_FIND_PACKAGE_PortMidi=$(usex !portmidi)
+ -DCMAKE_DISABLE_FIND_PACKAGE_PNG=$(usex !png)
+ -DCMAKE_DISABLE_FIND_PACKAGE_Readline=$(usex !readline)
+ -DCMAKE_DISABLE_FIND_PACKAGE_Udev=$(usex !udev)
+ -DCMAKE_DISABLE_FIND_PACKAGE_ZLIB=$(usex !zlib)
+ )
+ cmake-utils_src_configure
+}
+
+src_install() {
+ cmake-utils_src_install
+ python_fix_shebang "${ED}"/usr/share/${PN}/
+}
diff --git a/games-emulation/hatari/metadata.xml b/games-emulation/hatari/metadata.xml
index d4511e749d4..f17253687ee 100644
--- a/games-emulation/hatari/metadata.xml
+++ b/games-emulation/hatari/metadata.xml
@@ -6,6 +6,9 @@
<name>Gentoo Games Project</name>
</maintainer>
<use>
+ <flag name="capsimage">Use <pkg>dev-libs/spsdeclib</pkg> to read .IPF, .RAW, and .CTR disk images</flag>
+ <flag name="microphone">Use <pkg>media-libs/portaudio</pkg> for Falcon microphone handling</flag>
+ <flag name="portmidi">Use <pkg>media-libs/portmidi</pkg> as an alternative MIDI backend</flag>
<flag name="sdl2">Use libsdl2 instead of libsdl</flag>
</use>
</pkgmetadata>
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: games-emulation/hatari/files/, games-emulation/hatari/
@ 2021-06-02 2:38 Ionen Wolkens
0 siblings, 0 replies; 4+ messages in thread
From: Ionen Wolkens @ 2021-06-02 2:38 UTC (permalink / raw
To: gentoo-commits
commit: f161975e2a310eec02789128306f8bfb54af35a8
Author: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Tue Jun 1 11:59:26 2021 +0000
Commit: Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Wed Jun 2 02:20:51 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f161975e
games-emulation/hatari: add 2.3.1
- removed upstreamed joystick patch
- replaced default-rom patch by using /etc/hatari.cfg, effective even
if user has their own .cfg in $HOME unless overrides same option
- removed libsdl1 support, upstream advises against using and it'll
be removed entirely next version
- added python3_10 (haven't managed to find issues)
- the python-ui frontend was previously missing gtk+:3[introspection]
dep and, rather than add unconditionally, introducing USE=gui
- plus other small adjustments/fixes
bug 739146 config-file test failure was caused by the default-rom patch
Closes: https://bugs.gentoo.org/739146
Closes: https://bugs.gentoo.org/765004
Closes: https://bugs.gentoo.org/765115
Closes: https://github.com/gentoo/gentoo/pull/20905
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>
games-emulation/hatari/Manifest | 1 +
.../files/hatari-2.3.1-caps5-include-path.patch | 18 +++++
.../hatari-2.3.1-cmake-include-checksym.patch | 12 +++
games-emulation/hatari/hatari-2.3.1.ebuild | 90 ++++++++++++++++++++++
4 files changed, 121 insertions(+)
diff --git a/games-emulation/hatari/Manifest b/games-emulation/hatari/Manifest
index ed73c9b263e..aaf8342bc92 100644
--- a/games-emulation/hatari/Manifest
+++ b/games-emulation/hatari/Manifest
@@ -1 +1,2 @@
DIST hatari-2.2.1.tar.bz2 4162798 BLAKE2B 51938a649957779652b0debf7f867b2abe2d54fd3bb31086542f9f5970d01a120455e4381a9cb173724fbc7c45359d4009377bfe99038b338142fa5b82723533 SHA512 0e4c148a355a53c9cf79bdd28e5d7bb5f3389c780576017c6ebe2b69465d67522f373945f0e51681120ece24f5f08442265515486d2d7df7a02d9cd94cc44f1e
+DIST hatari-2.3.1.tar.bz2 4334129 BLAKE2B f309a31cbf181135b02858ebefa4d70116e66d252ef5de03cffa8254c0e86e4eeebfbf626613103790fb803d08028b318721020b292ea748c79e4d008e6d503d SHA512 78a6c7d80bfcd9b3a85a82754f4180cfd906eb95c6a44c8fbb92c2a648dc9c21c74c9dd18db4783d87259a3061b39e639c54cdd6c033d83de1252afef811382f
diff --git a/games-emulation/hatari/files/hatari-2.3.1-caps5-include-path.patch b/games-emulation/hatari/files/hatari-2.3.1-caps5-include-path.patch
new file mode 100644
index 00000000000..a12207b0958
--- /dev/null
+++ b/games-emulation/hatari/files/hatari-2.3.1-caps5-include-path.patch
@@ -0,0 +1,18 @@
+Gentoo's spsdeclib ebuild installs headers in caps5/
+while upstream now expects them in caps/
+
+See: https://github.com/hatari/hatari/commit/367a87b
+--- a/cmake/FindCapsImage.cmake
++++ b/cmake/FindCapsImage.cmake
+@@ -6,3 +6,3 @@
+
+-SET(CAPSIMAGE_DIR caps)
++SET(CAPSIMAGE_DIR caps5)
+ FIND_PATH(CAPSIMAGE_INCLUDE_DIR ${CAPSIMAGE_DIR}/CapsAPI.h)
+--- a/src/floppy_ipf.c
++++ b/src/floppy_ipf.c
+@@ -34,3 +34,3 @@
+ #endif
+-#include <caps/CapsLibAll.h>
++#include <caps5/CapsLibAll.h>
+ #define CapsLong SDWORD
diff --git a/games-emulation/hatari/files/hatari-2.3.1-cmake-include-checksym.patch b/games-emulation/hatari/files/hatari-2.3.1-cmake-include-checksym.patch
new file mode 100644
index 00000000000..39da11ea307
--- /dev/null
+++ b/games-emulation/hatari/files/hatari-2.3.1-cmake-include-checksym.patch
@@ -0,0 +1,12 @@
+Fix edge case build failure triggered by passing every
+DISABLE_FIND_PACKAGE, including disabling the normally
+always-enabled readline.
+
+CMake Error at CMakeLists.txt:229 (check_symbol_exists):
+ Unknown CMake command "check_symbol_exists".
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -12,2 +12,3 @@
+ include(CheckStructHasMember)
++include(CheckSymbolExists)
+ include(CheckCCompilerFlag)
diff --git a/games-emulation/hatari/hatari-2.3.1.ebuild b/games-emulation/hatari/hatari-2.3.1.ebuild
new file mode 100644
index 00000000000..2512ca06655
--- /dev/null
+++ b/games-emulation/hatari/hatari-2.3.1.ebuild
@@ -0,0 +1,90 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{7..10} )
+inherit cmake python-single-r1 xdg
+
+DESCRIPTION="Atari ST emulator"
+HOMEPAGE="https://hatari.tuxfamily.org/"
+SRC_URI="https://download.tuxfamily.org/hatari/${PV}/${P}.tar.bz2"
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="capsimage gui microphone png portmidi readline udev zlib"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+DEPEND="
+ ${PYTHON_DEPS}
+ media-libs/libsdl2[sound,video]
+ capsimage? ( >=dev-libs/spsdeclib-5.1-r1 )
+ microphone? ( media-libs/portaudio )
+ png? ( media-libs/libpng:= )
+ portmidi? ( media-libs/portmidi )
+ readline? ( sys-libs/readline:= )
+ udev? ( virtual/udev )
+ zlib? ( sys-libs/zlib:= )"
+RDEPEND="
+ ${DEPEND}
+ gui? (
+ $(python_gen_cond_dep '
+ dev-python/pygobject:3[${PYTHON_USEDEP}]
+ ')
+ x11-libs/gtk+:3[introspection]
+ )
+ >=games-emulation/emutos-0.9.9.1"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-caps5-include-path.patch
+ "${FILESDIR}"/${P}-cmake-include-checksym.patch
+)
+DOCS=(
+ readme.txt
+ doc/{bugs,changelog,scsi-driver,thanks,video-recording}.txt
+)
+
+src_prepare() {
+ cmake_src_prepare
+
+ sed -i "s/\.1\.gz\b/.1/g;T;s/gzip[^\$]*/cat /g" {*/,}*/CMakeLists.txt || die
+ sed -i "s:doc/${PN}:doc/${PF}:" python-ui/uihelpers.py || die
+ # Note: >2.3.1 renames /python/ to /python3/, update accordingly
+ sed -i "s/python/${EPYTHON}/;s/dosfs/fs.fat/" tools/atari-hd-image.sh || die
+
+ # Use emutos package rather than bundled ROM.
+ rm src/tos.img || die
+ cat <<-EOF > hatari.cfg || die
+ [ROM]
+ szTosImageFileName = ${EPREFIX}/usr/share/emutos/etos512k.img
+ EOF
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DBUILD_SHARED_LIBS=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_CapsImage=$(usex !capsimage)
+ -DCMAKE_DISABLE_FIND_PACKAGE_PNG=$(usex !png)
+ -DCMAKE_DISABLE_FIND_PACKAGE_PortAudio=$(usex !microphone)
+ -DCMAKE_DISABLE_FIND_PACKAGE_PortMidi=$(usex !portmidi)
+ -DCMAKE_DISABLE_FIND_PACKAGE_Readline=$(usex !readline)
+ -DCMAKE_DISABLE_FIND_PACKAGE_Udev=$(usex !udev)
+ -DCMAKE_DISABLE_FIND_PACKAGE_ZLIB=$(usex !zlib)
+ -DDOCDIR="${EPREFIX}"/usr/share/doc/${PF}
+ -DETCDIR="${EPREFIX}"/etc
+ $(usex gui '' -DPYTHON_EXECUTABLE=false) # disables python-ui/
+ )
+ cmake_src_configure
+}
+
+src_install() {
+ cmake_src_install
+
+ insinto /etc
+ doins hatari.cfg
+
+ python_fix_shebang "${ED}"/usr/bin
+ use gui && python_fix_shebang "${ED}"/usr/share/${PN}/${PN}ui
+}
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: games-emulation/hatari/files/, games-emulation/hatari/
@ 2024-03-14 6:06 Sam James
0 siblings, 0 replies; 4+ messages in thread
From: Sam James @ 2024-03-14 6:06 UTC (permalink / raw
To: gentoo-commits
commit: e27a8a83982e24d3f02d16e6ff92ca5fb475e571
Author: Eli Schwartz <eschwartz93 <AT> gmail <DOT> com>
AuthorDate: Thu Mar 14 04:52:10 2024 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Mar 14 06:05:30 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e27a8a83
games-emulation/hatari: backport fix for LTO
https://github.com/hatari/hatari/commit/adccd68b16eff815590c1ec993354ef8e752ecfd
Closes: https://bugs.gentoo.org/858704
Signed-off-by: Eli Schwartz <eschwartz93 <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../adccd68b16eff815590c1ec993354ef8e752ecfd.patch | 36 ++++++++++++++++++++++
...{hatari-2.4.1.ebuild => hatari-2.4.1-r1.ebuild} | 4 ++-
2 files changed, 39 insertions(+), 1 deletion(-)
diff --git a/games-emulation/hatari/files/adccd68b16eff815590c1ec993354ef8e752ecfd.patch b/games-emulation/hatari/files/adccd68b16eff815590c1ec993354ef8e752ecfd.patch
new file mode 100644
index 000000000000..d8623cb4d66b
--- /dev/null
+++ b/games-emulation/hatari/files/adccd68b16eff815590c1ec993354ef8e752ecfd.patch
@@ -0,0 +1,36 @@
+From adccd68b16eff815590c1ec993354ef8e752ecfd Mon Sep 17 00:00:00 2001
+From: Thomas Huth <huth@tuxfamily.org>
+Date: Thu, 21 Dec 2023 14:33:19 +0100
+Subject: [PATCH] Fix compiler warning that occurs with link-time optimization
+
+With LTO enable, the build fails with:
+
+ [100%] Linking C executable hatari
+ .../src/cpu/savestate.h:281:14: error: type of 'savestate_fname' does not
+ match original declaration [-Werror=lto-type-mismatch]
+ 281 | extern TCHAR savestate_fname[MAX_DPATH];
+ | ^
+ .../src/cpu/custom.c:40:8: note:
+ 'savestate_fname' was previously declared here
+ 40 | TCHAR *savestate_fname;
+ | ^
+ lto1: all warnings being treated as errors
+
+Declare the array according to the definition in the header file to fix it.
+---
+ src/cpu/custom.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/cpu/custom.c b/src/cpu/custom.c
+index 15971ceff..aff0c0253 100644
+--- a/src/cpu/custom.c
++++ b/src/cpu/custom.c
+@@ -37,7 +37,7 @@ extern struct regstruct mmu_backup_regs;
+ evt_t currcycle;
+ /* declared in savestate.h */
+ int savestate_state = 0;
+-TCHAR *savestate_fname;
++TCHAR savestate_fname[MAX_DPATH];
+ /* declared in custom.h */
+ uae_u32 hsync_counter = 0, vsync_counter = 0;
+ #endif
diff --git a/games-emulation/hatari/hatari-2.4.1.ebuild b/games-emulation/hatari/hatari-2.4.1-r1.ebuild
similarity index 93%
rename from games-emulation/hatari/hatari-2.4.1.ebuild
rename to games-emulation/hatari/hatari-2.4.1-r1.ebuild
index 34e97a9d20bf..c2bc4be39b99 100644
--- a/games-emulation/hatari/hatari-2.4.1.ebuild
+++ b/games-emulation/hatari/hatari-2.4.1-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -43,6 +43,8 @@ BDEPEND="${PYTHON_DEPS}"
PATCHES=(
"${FILESDIR}"/${PN}-2.3.1-caps5-include-path.patch
"${FILESDIR}"/${PN}-2.3.1-cmake-include-checksym.patch
+ # backport upstream patch for -Werror=lto-type-mismatch
+ "${FILESDIR}"/adccd68b16eff815590c1ec993354ef8e752ecfd.patch
)
DOCS=(
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-03-14 6:06 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-14 6:06 [gentoo-commits] repo/gentoo:master commit in: games-emulation/hatari/files/, games-emulation/hatari/ Sam James
-- strict thread matches above, loose matches on Subject: below --
2021-06-02 2:38 Ionen Wolkens
2019-11-10 21:39 James Le Cuirot
2018-07-13 9:27 Tony Vroon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox