update CI to FFmpeg 8.0.1, preserve avcodec_close() for older FFmpeg versions

This commit is contained in:
Adrian Siekierka
2025-12-05 07:38:38 +01:00
parent ac4dea75ea
commit 186c0fad10
2 changed files with 5 additions and 2 deletions

View File

@@ -1,7 +1,7 @@
#!/bin/bash
ROOT_DIR="$(pwd)"
FFMPEG_VERSION="7.1.1"
FFMPEG_VERSION="8.0.1"
NUM_JOBS="4"
if [ $# -eq 1 ]; then
@@ -44,7 +44,6 @@ cd ffmpeg-build
--disable-programs \
--disable-doc \
--disable-avdevice \
--disable-postproc \
--disable-avfilter \
--disable-network \
--disable-encoders \

View File

@@ -447,6 +447,10 @@ void close_av_data(decoder_t *decoder) {
av_frame_free(&(av->frame));
swr_free(&(av->resampler));
#if LIBAVCODEC_VERSION_MAJOR < 61
// Deprecated, kept for compatibility with older FFmpeg versions.
avcodec_close(av->audio_codec_context);
#endif
avcodec_free_context(&(av->audio_codec_context));
avformat_free_context(av->format);