summaryrefslogtreecommitdiff
path: root/games-action/dxx-rebirth/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-06-25 19:30:41 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-06-25 19:30:41 +0100
commit6fe5af3f06c92a6b1a6b21ff5e1bc9d107490971 (patch)
tree872ff7ba355a0b1735779b329c6a6b8b8f728a88 /games-action/dxx-rebirth/files
parente564f1661521043bc9e03e613c3cd8c79d5d7713 (diff)
gentoo auto-resync : 25:06:2023 - 19:30:41
Diffstat (limited to 'games-action/dxx-rebirth/files')
-rw-r--r--games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12-editor.patch23
-rw-r--r--games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12.patch25
-rw-r--r--games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-scons-4.5.patch51
-rw-r--r--games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20230618-sdl12-compat.patch38
4 files changed, 38 insertions, 99 deletions
diff --git a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12-editor.patch b/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12-editor.patch
deleted file mode 100644
index fbb03cf8f334..000000000000
--- a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12-editor.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-With USE=editor and gcc12:
-
- similar/main/piggy.cpp: In function 'void d2x::piggy_new_pigfile(char*)':
- similar/main/piggy.cpp:870:62: error: '%u' directive output may be truncated writing between 1 and 10 bytes into a region of size between 7 and 19 [-Werror=format-truncation=]
-
-But the offending code is unused, so can just drop it.
-
-Backport from:
-https://github.com/dxx-rebirth/dxx-rebirth/commit/12cca97870efe419613462dc279963a77bc80d9a
---- a/similar/main/piggy.cpp
-+++ b/similar/main/piggy.cpp
-@@ -889,11 +889,8 @@ void piggy_new_pigfile(char *pigname)
- }
-
- for (fnum=0;fnum<nframes; fnum++) {
-- char tempname[20];
- int SuperX;
-
-- snprintf(tempname, sizeof(tempname), "%s#%u", basename, fnum);
--
- //SuperX = (GameBitmaps[i+fnum].bm_flags&BM_FLAG_SUPER_TRANSPARENT)?254:-1;
- SuperX = (GameBitmapFlags[i+fnum]&BM_FLAG_SUPER_TRANSPARENT)?254:-1;
- //above makes assumption that supertransparent color is 254
diff --git a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12.patch b/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12.patch
deleted file mode 100644
index 3681385976a6..000000000000
--- a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-gcc-12.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-https://bugs.gentoo.org/894678
-https://github.com/dxx-rebirth/dxx-rebirth/commit/092daecb6118b3c072c71a8bea24f119e300bd49
-
-From 092daecb6118b3c072c71a8bea24f119e300bd49 Mon Sep 17 00:00:00 2001
-From: Kp <kp@valhallalegends.com>
-Date: Sat, 28 May 2022 21:04:37 +0000
-Subject: [PATCH] Use static_cast<> to convert player_marker_num to
- game_marker_index
-
-gcc-12 rejects the list initialization syntax. Switch to static_cast<>,
-which generates equivalent code.
-
-Reported-by: dbermond <https://github.com/dxx-rebirth/dxx-rebirth/issues/638>
---- a/similar/main/automap.cpp
-+++ b/similar/main/automap.cpp
-@@ -370,7 +370,7 @@ game_marker_index convert_player_marker_index_to_game_marker_index(const game_mo
- return static_cast<game_marker_index>((player_num * MAX_DROP_MULTI_COOP) + static_cast<unsigned>(player_marker_num));
- if (game_mode & GM_MULTI)
- return static_cast<game_marker_index>((player_num * MAX_DROP_MULTI_COMPETITIVE) + static_cast<unsigned>(player_marker_num));
-- return game_marker_index{player_marker_num};
-+ return static_cast<game_marker_index>(player_marker_num);
- }
-
- unsigned d_marker_state::get_markers_per_player(const game_mode_flags game_mode, const unsigned max_numplayers)
-
diff --git a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-scons-4.5.patch b/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-scons-4.5.patch
deleted file mode 100644
index 0adc507cada5..000000000000
--- a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20210623-scons-4.5.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-https://bugs.gentoo.org/902463
-
-https://github.com/dxx-rebirth/dxx-rebirth/pull/705
-https://github.com/dxx-rebirth/dxx-rebirth/commit/189ac23f61605903eb3eaa0004d287b7bd9296bc
---- a/SConstruct
-+++ b/SConstruct
-@@ -324,3 +324,3 @@
- def __init__(self,env,keyviews,_l=[]):
-- self.flags = {k: env.get(k, _l)[:] for k in itertools.chain.from_iterable(keyviews)}
-+ self.flags = {k: env.get(k, _l).copy() for k in itertools.chain.from_iterable(keyviews)}
- def restore(self,env):
-@@ -1493,3 +1493,3 @@
- user_settings.max_axes_per_joystick = user_settings.max_buttons_per_joystick = user_settings.max_hats_per_joystick = 0
-- successflags['CPPDEFINES'] = CPPDEFINES = successflags.get('CPPDEFINES', [])[:]
-+ successflags['CPPDEFINES'] = CPPDEFINES = successflags.get('CPPDEFINES', []).copy()
- # use Redbook if at least one of the following applies
-@@ -4608,3 +4608,3 @@
- for test in runtime_test_boost_tests:
-- LIBS = [] if test.nodefaultlibs else env['LIBS'][:]
-+ LIBS = [] if test.nodefaultlibs else env['LIBS'].copy()
- LIBS.append('boost_unit_test_framework')
-@@ -4850,3 +4850,3 @@
- kwargs['CXXFLAGS'] = (env['CXXFLAGS'] or []) + ['-E']
-- kwargs['CPPDEFINES'] = (env['CPPDEFINES'] or []) + [
-+ kwargs['CPPDEFINES'] = list(env['CPPDEFINES'] or []) + [
- # Define these tokens to themselves so that
-@@ -4870,3 +4870,3 @@
- def _apply_env_version_seq(self,env,_empty={}):
-- return _empty if self.user_settings.pch else {'CPPDEFINES' : env['CPPDEFINES'] + [('DXX_VERSION_SEQ', self.DXX_VERSION_SEQ)]}
-+ return _empty if self.user_settings.pch else {'CPPDEFINES' : list(env['CPPDEFINES']) + [('DXX_VERSION_SEQ', self.DXX_VERSION_SEQ)]}
- get_objects_similar_arch_ogl = DXXCommon.create_lazy_object_states_getter((LazyObjectState(sources=(
-@@ -4966,3 +4966,3 @@
- ),
-- transform_env = (lambda self, env: {'CPPDEFINES' : env['CPPDEFINES'] + env.__dxx_CPPDEFINE_SHAREPATH + env.__dxx_CPPDEFINE_git_version}),
-+ transform_env = (lambda self, env: {'CPPDEFINES' : list(env['CPPDEFINES']) + env.__dxx_CPPDEFINE_SHAREPATH + env.__dxx_CPPDEFINE_git_version}),
- transform_target=_apply_target_name,
-@@ -4976,3 +4976,3 @@
- ),
-- transform_env = (lambda self, env: {'CPPDEFINES' : env['CPPDEFINES'] + env.__dxx_CPPDEFINE_SHAREPATH}),
-+ transform_env = (lambda self, env: {'CPPDEFINES' : list(env['CPPDEFINES']) + env.__dxx_CPPDEFINE_SHAREPATH}),
- transform_target=_apply_target_name,
-@@ -5185,3 +5185,3 @@
- versid_build_environ = ['CXX', 'CPPFLAGS', 'CXXFLAGS', 'LINKFLAGS']
-- versid_cppdefines = env['CPPDEFINES'][:]
-+ versid_cppdefines = env['CPPDEFINES'].copy()
- extra_version = user_settings.extra_version
-@@ -5303,3 +5303,3 @@
- else:
-- syspath = sys.path[:]
-+ syspath = sys.path.copy()
- cocoa = 'common/arch/cocoa'
diff --git a/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20230618-sdl12-compat.patch b/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20230618-sdl12-compat.patch
new file mode 100644
index 000000000000..4c01c8cd0dbb
--- /dev/null
+++ b/games-action/dxx-rebirth/files/dxx-rebirth-0.61.0_pre20230618-sdl12-compat.patch
@@ -0,0 +1,38 @@
+From e9daf03769d8408719c1b420a133155cb700b9a2 Mon Sep 17 00:00:00 2001
+From: James Le Cuirot <chewi@gentoo.org>
+Date: Sun, 25 Jun 2023 15:16:55 +0100
+Subject: [PATCH] Skip SDL OpenGL build check when the SDL2 wrapper is detected
+
+The wrapper does not define SDL_VIDEO_OPENGL in SDL_config.h. This
+appears to be deliberate, although it's not entirely clear why.
+
+ /* Don't define most of the SDL backends, under the assumption checking for these against the headers won't work anyhow.
+ The exception is the X11 backend; you need its define to know if you can use its syswm interface. */
+
+We could check SDL2's SDL_config.h instead, but that seems awkward to
+pull off.
+
+Closes: https://github.com/dxx-rebirth/dxx-rebirth/issues/689
+---
+ SConstruct | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/SConstruct b/SConstruct
+index c98a22bc8..59210a802 100644
+--- a/SConstruct
++++ b/SConstruct
+@@ -1586,9 +1586,11 @@ static void terminate_handler()
+ init_cdrom = '0' if sdl2 else 'SDL_INIT_CDROM'
+ error_text_opengl_mismatch = f'Rebirth configured with OpenGL enabled, but SDL{sdl2} configured with OpenGL disabled. Disable Rebirth OpenGL or install an SDL{sdl2} with OpenGL enabled.'
+ test_opengl = (f'''
++#if !((SDL_MAJOR_VERSION == 1) && (SDL_MINOR_VERSION == 2) && (SDL_PATCHLEVEL >= 50))
+ #ifndef SDL_VIDEO_OPENGL
+ #error "{error_text_opengl_mismatch}"
+ #endif
++#endif
+ ''') if user_settings.opengl else ''
+ main = '''
+ SDL_RWops *ops = reinterpret_cast<SDL_RWops *>(argv);
+--
+2.40.1
+