Created attachment 790322 [details] GTK hard-dep patch Following a quick discussion on GitHub (PR 26127, I believe my account is too young for URLs), I have made the required changes to the new ebuild that was released today which will now allow us to build dwarf-fortress without having to pull GTK. For a quick explanation, the only reason GTK is pulled is for a small dialog when the game is opened which will ask if the user would like to enter fullscreen. The patch has been sitting in svenstaro/dwarf_fortress_unfuck (GitHub) for the past year and a half and I have been using it in order to play without pulling GTK. To briefly explain the patch, a make variable HAVE_GTK is introduced and is used to #ifdef all GTK code. If the game is run in a terminal, it should ask the user via. a simple stdin request. I don't pretend to be fluent in ebuilds, but I (hopefully) have done most of the work already. I have attached a diff with three file modifications: the ebuild, Makefile.native and my proposed patch. Thanks.
I've gone ahead and opened my own PR. See https://github.com/gentoo/gentoo/pull/26994
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1f452038d6b0f5b676e3d933d40f2fd5a797c576 commit 1f452038d6b0f5b676e3d933d40f2fd5a797c576 Author: Finn Rayment <finn@rayment.fr> AuthorDate: 2022-08-24 04:22:13 +0000 Commit: James Le Cuirot <chewi@gentoo.org> CommitDate: 2022-10-09 12:08:35 +0000 games-roguelike/dwarf-fortress: Added gui? USE flag and removed hard dep. GTK was required for runtime but was only used for a single fullscreen dialog prompt when the config [WINDOWED:PROMPT]. Now, if libgraphics is compiled without using GTK, the game will not ask at all if run from a window manager, but instead open in windowed mode. However, if the game is run from a terminal, a simple scanf procedure will ask the user for yes/no before deciding. Signed-off-by: Finn Rayment <finn@rayment.fr> Bug: https://bugs.gentoo.org/856685 Signed-off-by: James Le Cuirot <chewi@gentoo.org> ....05.ebuild => dwarf-fortress-0.47.05-r1.ebuild} | 7 +- .../dwarf-fortress/files/Makefile.native | 9 +- .../files/dwarf-fortress-0.47.05-nogtk.patch | 119 +++++++++++++++++++++ .../dwarf-fortress-0.47.05-segfault-fixes.patch | 16 ++- 4 files changed, 143 insertions(+), 8 deletions(-)
Closed as merged.