Install MPV (0.37.0 Updated) in Ubuntu 22.04, 23.10 via PPA

Last updated: November 22, 2023 — 10 Comments

MPV media player has reached version 0.37.0. Here’s how to install it for those sticking to the classic .deb package format.

MPV does not provide official packages for Ubuntu Linux. It’s however easy to install the latest version via different sources.

Linux Mint 21 can directly search for and install VLC Flatpak package from software manager. And, Ubuntu can install the Snap package from Ubuntu Software. Though, both of them run in sandbox.

For those sticking to the classic .deb package, I’ve upload MPV 0.37.0 into this unofficial PPA. It supports Ubuntu 22.04, Ubuntu 23.04/23.10, Ubuntu 20.04 on both x86_64 and arm64/armhf CPU architecture types.

Install MPV 0.37.0 via Ubuntu PPA

NOTE: The PPA also contains MPV 0.36.0 for Ubuntu 20.04.

1. Add the PPA

Firstly, press Ctrl+Alt+T on keyboard to open a terminal window. When it opens, paste the command below and hit run:

sudo add-apt-repository ppa:ubuntuhandbook1/mpv

Type user password (no asterisk feedback) when it asks and hit Enter to continue.

2. Update package cache

Since Ubuntu 20.04, it automatically updates the package cache while adding PPA. Though, Linux Mint user needs to do it manually.

To do so, run command in terminal:

sudo apt update

3. Install MPV 0.37.0

Finally, install mpv media player v0.37.0 by running command:

sudo apt install mpv

To verify, run mpv --version command in terminal.

Known Issues

Drag and drop files into mpv app window does not work, due to Wayland. Though, you may right-click on media file to open with mpv.

For hardware video acceleration, first make sure your graphics driver support it, then edit ‘/etc/mpv/mpv.conf‘ file and add hwdec=auto. And, enable classic header bar via gpu-context=x11egl.

Uninstall:

You can choose to purge the PPA repository, which will also downgrade mpv to the stock version in system repository. To do so, open terminal and run command:

sudo apt install ppa-purge && sudo ppa-purge ppa:ubuntuhandbook1/mpv

Or, remove PPA by running command:

sudo add-apt-repository --remove ppa:ubuntuhandbook1/mpv

To remove the mpv media player, use command:

sudo apt remove --autoremove mpv

Twitter

I'm a freelance blogger who started using Ubuntu in 2007 and wishes to share my experiences and some useful tips with Ubuntu beginners and lovers. Please comment to let me know if the tutorial is outdated! And, notify me if you find any typo/grammar/language mistakes. English is not my native language. Contact me via [email protected] Buy me a coffee: https://ko-fi.com/ubuntuhandbook1

10 responses to Install MPV (0.37.0 Updated) in Ubuntu 22.04, 23.10 via PPA

  1. The mpv packages in your repo have been built without libmujs.
    So only LUA plugins work.
    JS plugins fail with message:
    “Cannot find main.* for any supported scripting backend”

  2. Could you consider adding “avif” support?

    I suspect it would be enough to consider into account the remarks given at https://github.com/mpv-player/mpv/issues/12881

    • The AVIF support seems to reply on FFmpeg.

      The PPA package is built with FFmpeg from system repository. “AVIF” is supported in Ubuntu 23.10 in my case, but NOT for 22.04 due to different FFmpeg library.

      UPDATE: I’ve rebuild MPV 0.37.0 for Ubuntu 22.04 with FFmpeg 6.0 in bundle. It’s moved to this unstable PPA:

      https://launchpad.net/~ubuntuhandbook1/+archive/ubuntu/mpv-unstable/

      It seems working for me. Wait for your feedback.

      • Amazing job. Thanks a lot.

        I have just checked:
        – opening avif images
        – taking screenshots using avif format
        and both are working great.

      • The webp support for screenshots has been lost in this version. It is fine to open webp images, but now it is not working “mpv –screenshot-format=webp …”.

        Personally I am going to replace webp with avif in my configuration, so your version is OK for my aim. I just say so to let you know (in case you care).

        • was missing --enable-libwebp in the bundled FFmpeg build.

          The test PPA package you just tried is built with FFmpeg 6.0 (in bundle). Due to outdated dependency libraries in 22.04 repositories, many features may be disabled.
          The stable PPA introduced in this tutorial is built with FFmpeg from system repository, but it’s old and lack the feature that you required.

          Now, I don’t know which one should be kept in PPA …

          • may i suggest for stable PPA you retain dependency on older version of the libs in the system repo?
            this will keep things simple.
            folks who want features based on the latest libs can use your test PPA.
            you can probably add a note in the article to indidcate this.

  3. This is your choice.

    What I have done is keeping your two “mpv” binary files for ubuntu 22.04 in my /usr/bin/folder . I obviously use different names (while one is “mpv” the other is renamed “mpv-withavifbut”). Depending what I want to do I choose the right one.

    Perhaps you could consider including both binaries inside your deb package and inform about this in the documentation (mainly the drawbacks in the version with avif support). Nevertheless, I expect (but I have no idea) that the missing avif support will be solved in the LTS release Ubuntu 24,04

Leave a Reply

Text formatting is available via select HTML.

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> 

*