From 7c5fef884e2da02f517cdc8cd2965a1b20f17d37 Mon Sep 17 00:00:00 2001 From: Diederik Hamelink Date: Fri, 24 Jul 2026 14:25:20 +0200 Subject: [PATCH] Fix unable to load *.so plugins python3-mpv loads libmpv with RTLD_LOCAL, preventing C plugins such as mpv-mpris from resolving libmpv symbols. --- mpv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mpv.py b/mpv.py index f9bf561..7d06c09 100644 --- a/mpv.py +++ b/mpv.py @@ -70,7 +70,7 @@ sofile = ctypes.util.find_library('mpv') if sofile is None: raise OSError("Cannot find libmpv in the usual places. Depending on your distro, you may try installing an mpv-devel or mpv-libs package. If you have libmpv around but this script can't find it, consult the documentation for ctypes.util.find_library which this script uses to look up the library filename.") - backend = CDLL(sofile) + backend = CDLL(sofile, ctypes.RTLD_GLOBAL) fs_enc = sys.getfilesystemencoding()