Commit Graph

5 Commits

Author SHA1 Message Date
Kacper Michajłow baabc291f1 build: fix dynamic generation of mpv.desktop file protocols
Running cross-compiled binaries may be possible, but the runtime
environment must be configured correctly. In some configurations, an
exe_wrapper needs to be used, and in all cases, the library path must be
set correctly for the given binary. Fortunately, Meson handles all of
this if cross-compilation is configured correctly.

Fix this by having Meson run the mpv binary directly, instead of as a
subprocess of a Python script. This ensures that the environment is
properly set for running host binaries, if possible.

Fixes: #15075
Fixes: 056b03f9ed
2024-10-14 01:56:25 +02:00
Nathan Ruiz 1562895af7 ci/lint: add pyupgrade check 2024-10-06 22:15:08 +02:00
Nathan Ruiz e5a383a525 ci/lint: enable pyflakes and pycodestyle checks
This change required some minor rework to make the code conform to the
following:
- Restrict line length to 88 character
- Use spaces rather than tabs (only affect ci/lint-commit-msg.py)
- Use f-strings rather than % formatting or `str.format()`
2024-10-06 22:15:08 +02:00
llyyr c7dce6a838 TOOLS/gen-mpv-desktop.py: set --no-config when probing protocols
Apparently for an user mpv would crash on startup if built with asan and
mpv attemps to load mpv-mpris. Just set --no-config so we don't load
anything external since this is more correct anyway.
2024-09-15 20:10:29 +02:00
Dudemanguy 056b03f9ed build: dynamically generate mpv.desktop file protocols
If we can run the built mpv binary, then it is possible to use a custom
target that reads the protocols we have available in mpv and write the
mpv.desktop file based on the output. For cases where this is not
possible (e.g. cross compiling), then just install the unmodified
mpv.desktop file like before. Fixes #8731 and fixes #14124.
2024-05-22 20:10:52 +00:00