av_log: sort library version print and add missing libavdevice

Incidentally sorted list put more important libs to the top.
This commit is contained in:
Kacper Michajłow 2024-06-22 13:25:07 +02:00
parent 9e1271260f
commit e5d85704a3
1 changed files with 6 additions and 3 deletions

View File

@ -194,12 +194,15 @@ struct lib {
void check_library_versions(struct mp_log *log, int v) void check_library_versions(struct mp_log *log, int v)
{ {
const struct lib libs[] = { const struct lib libs[] = {
{"libavutil", LIBAVUTIL_VERSION_INT, avutil_version()},
{"libavcodec", LIBAVCODEC_VERSION_INT, avcodec_version()}, {"libavcodec", LIBAVCODEC_VERSION_INT, avcodec_version()},
{"libavformat", LIBAVFORMAT_VERSION_INT, avformat_version()}, #if HAVE_LIBAVDEVICE
{"libswscale", LIBSWSCALE_VERSION_INT, swscale_version()}, {"libavdevice", LIBAVDEVICE_VERSION_INT, avdevice_version()},
#endif
{"libavfilter", LIBAVFILTER_VERSION_INT, avfilter_version()}, {"libavfilter", LIBAVFILTER_VERSION_INT, avfilter_version()},
{"libavformat", LIBAVFORMAT_VERSION_INT, avformat_version()},
{"libavutil", LIBAVUTIL_VERSION_INT, avutil_version()},
{"libswresample", LIBSWRESAMPLE_VERSION_INT, swresample_version()}, {"libswresample", LIBSWRESAMPLE_VERSION_INT, swresample_version()},
{"libswscale", LIBSWSCALE_VERSION_INT, swscale_version()},
}; };
mp_msg(log, v, "FFmpeg version: %s\n", av_version_info()); mp_msg(log, v, "FFmpeg version: %s\n", av_version_info());