Loading pkgs/by-name/st/stepmania/ffmpeg-7.patch 0 → 100644 +11 −0 Original line number Diff line number Diff line --- a/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp +++ b/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp @@ -273,7 +273,7 @@ bool bSkipThisFrame = fTargetTime != -1 && GetTimestamp() + GetFrameDuration() < fTargetTime && - (m_pStreamCodec->frame_number % 2) == 0; + (m_pStreamCodec->frame_num % 2) == 0; int iGotFrame; int len; pkgs/by-name/st/stepmania/package.nix +19 −13 Original line number Diff line number Diff line Loading @@ -6,10 +6,10 @@ cmake, nasm, alsa-lib, ffmpeg_6, ffmpeg_7, glew, glib, gtk2, gtk3, libmad, libogg, libpng, Loading @@ -32,12 +32,20 @@ stdenv.mkDerivation { }; patches = [ # https://github.com/stepmania/stepmania/pull/2247 (fetchpatch { name = "fix-building-with-ffmpeg6.patch"; url = "https://github.com/stepmania/stepmania/commit/3fef5ef60b7674d6431f4e1e4ba8c69b0c21c023.patch"; # Fix building with newer FFmpeg name = "fix-building-with-newer-ffmpeg.patch"; url = "https://github.com/stepmania/stepmania/commit/3fef5ef60b7674d6431f4e1e4ba8c69b0c21c023.patch?full_index=1"; hash = "sha256-m+5sP+mIpcSjioRBdzChqja5zwNcwdSNAfvSJ2Lww+g="; }) (fetchpatch { # Fix crash on loading animated previews while using newer FFmpeg name = "fix-crash-newer-ffmpeg.patch"; url = "https://github.com/stepmania/stepmania/commit/e0d2a5182dcd855e181fffa086273460c553c7ff.patch?full_index=1"; hash = "sha256-XacaMn29FwG3WgFBfB890I8mzVrvuOL4wPWcHHNYfXM="; }) # FFmpeg 7 frame_number compatibility fix ./ffmpeg-7.patch ]; postPatch = '' Loading @@ -54,10 +62,10 @@ stdenv.mkDerivation { buildInputs = [ alsa-lib ffmpeg_6 ffmpeg_7 glew glib gtk2 gtk3 libmad libogg libpng Loading @@ -72,8 +80,6 @@ stdenv.mkDerivation { "-DWITH_SYSTEM_FFMPEG=1" "-DWITH_SYSTEM_PNG=on" "-DWITH_SYSTEM_ZLIB=on" "-DGTK2_GDKCONFIG_INCLUDE_DIR=${gtk2.out}/lib/gtk-2.0/include" "-DGTK2_GLIBCONFIG_INCLUDE_DIR=${glib.out}/lib/glib-2.0/include" ]; postInstall = '' Loading @@ -86,12 +92,12 @@ stdenv.mkDerivation { install -Dm444 $src/stepmania.desktop -t $out/share/applications ''; meta = with lib; { meta = { homepage = "https://www.stepmania.com/"; description = "Free dance and rhythm game for Windows, Mac, and Linux"; platforms = platforms.linux; license = licenses.mit; # expat version maintainers = with maintainers; [ h7x4 ]; platforms = lib.platforms.linux; license = lib.licenses.mit; # expat version maintainers = with lib.maintainers; [ h7x4 ]; mainProgram = "stepmania"; }; } Loading
pkgs/by-name/st/stepmania/ffmpeg-7.patch 0 → 100644 +11 −0 Original line number Diff line number Diff line --- a/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp +++ b/src/arch/MovieTexture/MovieTexture_FFMpeg.cpp @@ -273,7 +273,7 @@ bool bSkipThisFrame = fTargetTime != -1 && GetTimestamp() + GetFrameDuration() < fTargetTime && - (m_pStreamCodec->frame_number % 2) == 0; + (m_pStreamCodec->frame_num % 2) == 0; int iGotFrame; int len;
pkgs/by-name/st/stepmania/package.nix +19 −13 Original line number Diff line number Diff line Loading @@ -6,10 +6,10 @@ cmake, nasm, alsa-lib, ffmpeg_6, ffmpeg_7, glew, glib, gtk2, gtk3, libmad, libogg, libpng, Loading @@ -32,12 +32,20 @@ stdenv.mkDerivation { }; patches = [ # https://github.com/stepmania/stepmania/pull/2247 (fetchpatch { name = "fix-building-with-ffmpeg6.patch"; url = "https://github.com/stepmania/stepmania/commit/3fef5ef60b7674d6431f4e1e4ba8c69b0c21c023.patch"; # Fix building with newer FFmpeg name = "fix-building-with-newer-ffmpeg.patch"; url = "https://github.com/stepmania/stepmania/commit/3fef5ef60b7674d6431f4e1e4ba8c69b0c21c023.patch?full_index=1"; hash = "sha256-m+5sP+mIpcSjioRBdzChqja5zwNcwdSNAfvSJ2Lww+g="; }) (fetchpatch { # Fix crash on loading animated previews while using newer FFmpeg name = "fix-crash-newer-ffmpeg.patch"; url = "https://github.com/stepmania/stepmania/commit/e0d2a5182dcd855e181fffa086273460c553c7ff.patch?full_index=1"; hash = "sha256-XacaMn29FwG3WgFBfB890I8mzVrvuOL4wPWcHHNYfXM="; }) # FFmpeg 7 frame_number compatibility fix ./ffmpeg-7.patch ]; postPatch = '' Loading @@ -54,10 +62,10 @@ stdenv.mkDerivation { buildInputs = [ alsa-lib ffmpeg_6 ffmpeg_7 glew glib gtk2 gtk3 libmad libogg libpng Loading @@ -72,8 +80,6 @@ stdenv.mkDerivation { "-DWITH_SYSTEM_FFMPEG=1" "-DWITH_SYSTEM_PNG=on" "-DWITH_SYSTEM_ZLIB=on" "-DGTK2_GDKCONFIG_INCLUDE_DIR=${gtk2.out}/lib/gtk-2.0/include" "-DGTK2_GLIBCONFIG_INCLUDE_DIR=${glib.out}/lib/glib-2.0/include" ]; postInstall = '' Loading @@ -86,12 +92,12 @@ stdenv.mkDerivation { install -Dm444 $src/stepmania.desktop -t $out/share/applications ''; meta = with lib; { meta = { homepage = "https://www.stepmania.com/"; description = "Free dance and rhythm game for Windows, Mac, and Linux"; platforms = platforms.linux; license = licenses.mit; # expat version maintainers = with maintainers; [ h7x4 ]; platforms = lib.platforms.linux; license = lib.licenses.mit; # expat version maintainers = with lib.maintainers; [ h7x4 ]; mainProgram = "stepmania"; }; }