Hi ports --

Attached is a quite straightforward update to CorsixTH. Upstream tagged
the code but hasn't yet made the formal release.

Changelog is here:
https://github.com/CorsixTH/CorsixTH/compare/v0.66...v0.67

A big endian test would be appreciated. It's fine on amd64 and i386,
even on a paltry little n270 atom netbook.

OK?

~Brian
Index: Makefile
===================================================================
RCS file: /cvs/ports/games/corsixth/Makefile,v
retrieving revision 1.15
diff -u -p -r1.15 Makefile
--- Makefile	13 May 2023 18:01:55 -0000	1.15
+++ Makefile	9 Aug 2023 00:16:34 -0000
@@ -1,6 +1,4 @@
-ONLY_FOR_ARCHS =	${CXX11_ARCHS}
-
-V =		0.66
+V =		0.67
 COMMENT =	open source clone of Theme Hospital
 PKGNAME =	corsixth-${V}
 CATEGORIES =	games x11
@@ -36,8 +34,8 @@ RUN_DEPENDS =	audio/timidity \
 
 NO_TEST =	Yes
 
-# Remove the .orig file
+# Remove the .orig.port file
 post-install:
-	@rm -f ${PREFIX}/share/corsix-th/Lua/app.lua.orig
+	@rm -f ${PREFIX}/share/corsix-th/Lua/app.lua.orig.port
 
 .include <bsd.port.mk>
Index: distinfo
===================================================================
RCS file: /cvs/ports/games/corsixth/distinfo,v
retrieving revision 1.8
diff -u -p -r1.8 distinfo
--- distinfo	13 May 2023 18:01:55 -0000	1.8
+++ distinfo	9 Aug 2023 00:16:34 -0000
@@ -1,2 +1,2 @@
-SHA256 (CorsixTH-0.66.tar.gz) = n4f/ACQFUBsSeYpxW2kUlndaT5cnGI7roWcUOBaZKg8=
-SIZE (CorsixTH-0.66.tar.gz) = 4117046
+SHA256 (CorsixTH-0.67.tar.gz) = TojPGRa/TXwwS1Ud25H7kZTxELrUZjA4ynPTG5OdaeM=
+SIZE (CorsixTH-0.67.tar.gz) = 4127698
Index: patches/patch-CorsixTH_Lua_app_lua
===================================================================
RCS file: /cvs/ports/games/corsixth/patches/patch-CorsixTH_Lua_app_lua,v
retrieving revision 1.4
diff -u -p -r1.4 patch-CorsixTH_Lua_app_lua
--- patches/patch-CorsixTH_Lua_app_lua	13 May 2023 18:01:55 -0000	1.4
+++ patches/patch-CorsixTH_Lua_app_lua	9 Aug 2023 00:16:34 -0000
@@ -9,6 +9,6 @@ Index: CorsixTH/Lua/app.lua
    self.savegame_version = SAVEGAME_VERSION
 -  self.check_for_updates = true
 +  self.check_for_updates = false
+   self.idle_tick = 0
  end
  
- --! Starts a Lua DBGp client & connects it to a DBGp server.
Index: patches/patch-CorsixTH_Src_th_movie_cpp
===================================================================
RCS file: patches/patch-CorsixTH_Src_th_movie_cpp
diff -N patches/patch-CorsixTH_Src_th_movie_cpp
--- patches/patch-CorsixTH_Src_th_movie_cpp	13 May 2023 18:01:55 -0000	1.1
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,44 +0,0 @@
-Use ffmpeg 5.1 new channel layout api
-
-Index: CorsixTH/Src/th_movie.cpp
---- CorsixTH/Src/th_movie.cpp.orig
-+++ CorsixTH/Src/th_movie.cpp
-@@ -446,9 +446,29 @@ void movie_player::play(int iChannel) {
-       default:
-         std::cerr << "WARN: unsupported channel layout " << mixer_channels
-                   << ". Please report issue.";
--        target_channel_layout = av_get_default_channel_layout(mixer_channels);
-+        target_channel_layout = 0;
-     }
- 
-+#if LIBAVUTIL_VERSION_INT >= AV_VERSION_INT(57, 24, 100) && \
-+    LIBSWRESAMPLE_VERSION_INT >= AV_VERSION_INT(4, 5, 100)
-+    av_channel_layout_unique_ptr ch_layout(new AVChannelLayout{});
-+
-+    if (target_channel_layout == 0) {
-+      av_channel_layout_default(ch_layout.get(), mixer_channels);
-+    } else {
-+      av_channel_layout_from_mask(ch_layout.get(), target_channel_layout);
-+    }
-+
-+    swr_alloc_set_opts2(&audio_resample_context, ch_layout.get(),
-+                        AV_SAMPLE_FMT_S16, mixer_frequency,
-+                        &(audio_codec_context->ch_layout),
-+                        audio_codec_context->sample_fmt,
-+                        audio_codec_context->sample_rate, 0, nullptr);
-+#else
-+    if (target_channel_layout == 0) {
-+      target_channel_layout = av_get_default_channel_layout(mixer_channels);
-+    }
-+
-     audio_resample_context = swr_alloc_set_opts(
-         audio_resample_context,
-         static_cast<std::int64_t>(target_channel_layout), AV_SAMPLE_FMT_S16,
-@@ -456,6 +476,7 @@ void movie_player::play(int iChannel) {
-         static_cast<std::int64_t>(audio_codec_context->channel_layout),
-         audio_codec_context->sample_fmt, audio_codec_context->sample_rate, 0,
-         nullptr);
-+#endif
-     swr_init(audio_resample_context);
-     empty_audio_chunk.reset(
-         Mix_QuickLoad_RAW(audio_chunk_buffer.data(),
Index: patches/patch-CorsixTH_Src_th_movie_h
===================================================================
RCS file: patches/patch-CorsixTH_Src_th_movie_h
diff -N patches/patch-CorsixTH_Src_th_movie_h
--- patches/patch-CorsixTH_Src_th_movie_h	13 May 2023 18:01:55 -0000	1.1
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,27 +0,0 @@
-Use ffmpeg 5.1 new channel layout api
-
-Index: CorsixTH/Src/th_movie.h
---- CorsixTH/Src/th_movie.h.orig
-+++ CorsixTH/Src/th_movie.h
-@@ -96,6 +96,21 @@ class mix_chunk_deleter {
- 
- using mix_chunk_unique_ptr = std::unique_ptr<Mix_Chunk, mix_chunk_deleter>;
- 
-+#if LIBAVUTIL_VERSION_INT >= AV_VERSION_INT(57, 24, 100)
-+//! \brief Functor for deleting AVChannelLayout
-+class av_channel_layout_deleter {
-+ public:
-+  void operator()(AVChannelLayout* c) {
-+    av_channel_layout_uninit(c);
-+    delete c;
-+  }
-+};
-+
-+//! \brief unique_ptr for AVChannelLayout
-+using av_channel_layout_unique_ptr =
-+    std::unique_ptr<AVChannelLayout, av_channel_layout_deleter>;
-+#endif
-+
- //! \brief A picture in movie_picture_buffer
- //!
- //! Stores the picture from a frame in the movie from the time that it is

Reply via email to