You are not logged in.

#1 2014-01-21 17:26:23

Registered: 2013-07-19
Posts: 25

[SOLVED] Getting mpv player to work in the framebuffer


I can't get mpv to display video with framebuffer/directfb.

Would adding


to the PKGBUILD enable it?
If so, how do I /petition for it?

(I haven't been able to actually try it out, because I keep getting errors with Waf, when trying to compile from source.)

Last edited by idomeneo (2014-01-22 15:05:06)


#2 2014-01-21 17:44:37

Registered: 2009-05-06
Posts: 25,440

Re: [SOLVED] Getting mpv player to work in the framebuffer

Post the errors you're getting.

If it's possible to compile it yourself using ABS, the developers may decline the feature request (open one in the bug tracker).


#3 2014-01-21 18:05:50

Registered: 2013-07-19
Posts: 25

Re: [SOLVED] Getting mpv player to work in the framebuffer

OK I'll post it as a "bug". Other apps seem to be compiled to work with framebuffer if available.

(Also I don't have time atm to sit through more compiling of this. I forget the last error, but the first one was that the /use/lib/waf couldn't be written to, but the permissions were correct, and I was using makepkg -s. I was also adapting the PKGBUILD from the general repo, not AUR. I gave the dir global write permission, and that got that working, but the error didn't seem to make much sense.)


#4 2014-01-21 18:11:42

Registered: 2009-05-06
Posts: 25,440

Re: [SOLVED] Getting mpv player to work in the framebuffer

Install mpv-git from jelle's unofficial repo: … ries#jelle , it has sdl2 among its dependencies, see if it works in the framebuffer.


#5 2014-01-21 18:25:34

Registered: 2009-08-25
Posts: 3,605

Re: [SOLVED] Getting mpv player to work in the framebuffer

SDL2 needs to be compiled with directfb in order to support the framebuffer console, I'm not sure that's the case with the Arch SDL2 package.


#6 2014-01-22 15:02:31

Registered: 2013-07-19
Posts: 25

Re: [SOLVED] Getting mpv player to work in the framebuffer

Okaaaay, I got the build to work.
(Libreoffice required python, but didn't recognize python2, so I linked /usr/bin/python to /usr/bin/python2. 1.6M mpv has 158M in make-dependencies including python3, which wanted the /usr/bin/python slot, and refused to install because it couldn't get it. Removing the python link and installing python3 fixed the build problems.)

Gusar, you're right, sdl2 autodetects many things but not directfb, which needs to be compiled in, which the Arch package doesn't do.

  --enable-sdl             enable SDL audio output [disable]
  --enable-sdl2            enable SDL 2.0+ audio and video output [disable]

  --enable-video-directfb        use DirectFB video driver [[default=no]]

Sdl2 also comes with instructions for directfb:

SDL on DirectFB


- Hardware YUV overlays
- OpenGL - software only
- 2D/3D accelerations (depends on directfb driver)
- multiple displays
- windows

What you need:

DirectFB 1.0.1, 1.2.x, 1.3.0
Kernel-Framebuffer support: required: vesafb, radeonfb ....  ( on Arch)
Mesa 7.0.x	   - optional for OpenGL


This file should contain the following lines to make
your joystick work and avoid crashes:

To disable to use x11 backend when DISPLAY variable is found use


To disable the use of linux input devices, i.e. multimice/multikeyboard support,


To use hardware accelerated YUV-overlays for YUV-textures, use:


This is disabled by default. It will only support one 
YUV texture, namely the first. Every other YUV texture will be
rendered in software.

In addition, you may use (directfb-1.2.x)


to make the YUV texture an underlay. This will make the cursor to
be shown.

Simple Window Manager

The driver has support for a very, very basic window manager you may
want to use when running with "wm=default". Use


to enable basic window borders. In order to have the window title rendered,
you need to have the following font installed:


OpenGL Support

The following instructions will give you *software* OpenGL. However this
works at least on all directfb supported platforms.

As of this writing 20100802 you need to pull Mesa from git and do the following:

git clone git://
cd mesa 
git checkout 2c9fdaf7292423c157fc79b5ce43f0f199dd753a

Edit configs/linux-directfb so that the Directories-section looks like
# Directories
SRC_DIRS     = mesa glu 
GLU_DIRS     = sgi
DRIVER_DIRS  = directfb

make linux-directfb

echo Installing - please enter sudo pw.

sudo make install INSTALL_DIR=/usr/local/dfb_GL
cd src/mesa/drivers/directfb
sudo make install INSTALL_DIR=/usr/local/dfb_GL

To run the SDL - testprograms:

export SDL_VIDEODRIVER=directfb
export LD_LIBRARY_PATH=/usr/local/dfb_GL/lib
export LD_PRELOAD=/usr/local/dfb_GL/


Last edited by idomeneo (2014-01-22 15:32:47)


#7 2014-01-22 15:19:32

Registered: 2009-05-06
Posts: 25,440

Re: [SOLVED] Getting mpv player to work in the framebuffer

When posting configs, code or command output, please use [ code ] tags, not [ quote ] tags

like this

It makes the code more readable and - in case of longer listings - more convenient to scroll through.


#8 2014-01-22 15:53:20

Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 9,806

Re: [SOLVED] Getting mpv player to work in the framebuffer

idomeneo wrote:

(Libreoffice required python, but didn't recognize python2, so I linked /usr/bin/python to /usr/bin/python2.

Just a heads up, that may cause you problems down the line. In theory, scripts that call for "python" should be able to run in either python2 or python3 [1]

  • In order to tolerate differences across platforms, all new code that needs to invoke the Python interpreter should not specify python, but rather should specify either python2 or python3 (or the more specific python2.x and python3.x versions; see the Migration Notes). This distinction should be made in shebangs, when invoking from a shell script, when invoking via the system() call, or when invoking in any other context.

  • One exception to this is scripts that are deliberately written to be source compatible with both Python 2.x and 3.x. Such scripts may continue to use python on their shebang line without affecting their portability.

But in practicality, a lot of scripts are written with the assumption that '/usr/bin/env python', or '/usr/bin/python' will always get them the python shell they get on the machine that they were developed on. Arch moved to python3 being /usr/bin/python over three years ago [2], so there's a chance that some Arch packages call for python, but are expecting python3.

If you end up getting a lot of python stack traces in your journal/logs, this is (probably) why. In the event that you do find some Arch packages that complain about python being the wrong python, you should open a bug report for the package in question (either in Arch's bug tracker, or upstream's).

You'll also get an error if you ever try to install the python package, as that package provides the /usr/bin/python file (which you have just created). If that happens, you'll need to remove the symlink.


Mobo: MSI X299 TOMAHAWK ARCTIC // Processor: Intel Core i7-7820X 3.6GHz // GFX: nVidia GeForce GTX 970 // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 5x 1TB HDD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.


Board footer

Powered by FluxBB