summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--common/av_log.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/common/av_log.c b/common/av_log.c
index bfd9a836e8..804972889f 100644
--- a/common/av_log.c
+++ b/common/av_log.c
@@ -207,17 +207,29 @@ void print_libav_versions(struct mp_log *log, int v)
mp_msg(log, v, "%s library versions:\n", LIB_PREFIX);
+ bool mismatch = false;
for (int n = 0; n < MP_ARRAY_SIZE(libs); n++) {
const struct lib *l = &libs[n];
mp_msg(log, v, " %-15s %d.%d.%d", l->name, V(l->buildv));
- if (l->buildv != l->runv)
+ if (l->buildv != l->runv) {
mp_msg(log, v, " (runtime %d.%d.%d)", V(l->runv));
+ mismatch = true;
+ }
mp_msg(log, v, "\n");
}
#if HAVE_AV_VERSION_INFO
mp_msg(log, v, "%s version: %s\n", LIB_PREFIX, av_version_info());
#endif
+
+ if (mismatch) {
+ // Using mismatched libraries can be legitimate, but even then it's
+ // a bad idea. We don't acknowledge its usefulness and stability.
+ mp_warn(log, "Warning: mpv was compiled against a different version of "
+ "%s than the shared\nlibrary it is linked against. This is "
+ "most likely a broken build\nand misbehavior and crashes are "
+ "to be expected.\n", LIB_PREFIX);
+ }
}
#undef V