Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Raspberry Pi 2 Kodi ERROR: Failed to determine egl config
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
keet
Guru
Guru


Joined: 09 Sep 2008
Posts: 568

PostPosted: Thu Feb 26, 2015 3:55 am    Post subject: Raspberry Pi 2 Kodi ERROR: Failed to determine egl config Reply with quote

As the title says, I'm trying to run Kodi on my Raspberry Pi 2.

/home/kodi/ fills with files like kodi_crashlog-20150225_202813.log, all saying the same thing. This seems to be the relevant part:

Code:

22:43:30 T:1952407552  NOTICE: Checking resolution 16
22:43:31 T:1952407552 WARNING: Visual 0x21 of the SDL window is not suitable, looking for another one...
22:43:31 T:1952407552   ERROR: Failed to determine egl config for visual info
22:43:31 T:1952407552   ERROR: Previous line repeats 116 times.
22:43:31 T:1952407552   ERROR: EGL/GLX Error: vInfo is NULL!


I followed the instructions at http://wiki.gentoo.org/wiki/Kodi and emerged raspberrypi-userland. I also installed the other raspberrypi-{firmware,kernel} packages, but these are much older than what I had before, and they did not help, so I reverted to my more recent firmware and kernel.

I tried Kodi 14.1 and 9999, but neither worked. 14.1's error was slightly different, as it complained about the colour depth, but maybe I will go back and try that one just in case. I had trouble installing either because of missing net-libs/libmicrohttpd and gles2 libraries, which I got by adding the USE flag to mesa. I also had fun installing icedtea using gcj instead of icedtea-bin.

From my searches, it might be related to graphics drivers, but the threads that I found were not for people using Raspberry Pis, so they might not really be related.

I know that this will probably go to unsupported software because Kodi is not even marked for ARM, but I've spent much time trying to make this work, so I would really appreciate some help. I guess that I could go back and use RaspBMC or OSMC, but I want to do a bit more with it than those will let me.
Back to top
View user's profile Send private message
Leio
Developer
Developer


Joined: 27 Feb 2003
Posts: 494
Location: Estonia

PostPosted: Thu Feb 26, 2015 4:52 pm    Post subject: Reply with quote

Unless you have a modified mesa ebuild, which builds new VC4 driver, and a special kernel that has KMS for it, you shouldn't be using mesa to provide gles2.
I've added a rough modified kodi ebuild in my overlay for you to test - you could try that and let me know how that goes ("layman -a leio" or something, I suppose). Compared to tree version, it has a USE=rpi to modify dependencies to be satisfied with raspberrypi-userland instead of mesa[gles2], and to pass --with-platform=raspberry-pi to kodi configure then.
I have not tested it whatsoever (other than looking the specific changes work, i.e the --with-platform flag is actually passed with USE=rpi), but might get you further along, especially if previous try already got you a successful build, just failing at runtime.
You probably want at least USE="-opengl gles rpi" for it.

Kodi 14.1 configure seems to still assume --with-platform=raspberry-pi means armv6, etc. So it disables NEON, potentially passes some armv6 CFLAGS, etc. Almost better to not pass it, but it's probably needed to have Kodi to use bcm_host, mmal and co for the video initialization and so on.
Now that I think of it, it probably will fail configure by not finding the headers, as gentoo raspberrypi-userland keeps them in /opt/vc. In which case I'd want to see the build log and can pass the necessary append-cppflags or whatnot. Or a git format-patch formatted fix to my overlay also good ;)

I also have a newer raspberrypi-userland in there. You really should upgrade to at least that, if you have a rpi2, because ancient version in main tree is probably not RPi2 compatible yet. The whole overlay is mostly only stuff for RPi, really.

I'm best reachable over IRC (leio on FreeNode network, where all the gentoo stuff is - #gentoo-embedded, #rpi-gentoo, privmsg, whatever), but occasionally stroll this subforum for now.
_________________
GNOME team lead; GStreamer; MIPS/ARM64
Back to top
View user's profile Send private message
keet
Guru
Guru


Joined: 09 Sep 2008
Posts: 568

PostPosted: Fri Feb 27, 2015 2:59 am    Post subject: Reply with quote

Thank you for all that information and help. I am going to post my progress here as a sort of log. I installed the newer userland, and when I tried to install Kodi from your overlay, configure did fail with this error:

Code:

checking for main in -lgpg-error... no
configure: error: Could not find a required library. Please see the README for your platform.


I might need to add something like

Code:

LDFLAGS="-L/opt/vc/lib/"


But I'll wait until tomorrow (hopefully only that long) for that, and post what happens.
Back to top
View user's profile Send private message
keet
Guru
Guru


Joined: 09 Sep 2008
Posts: 568

PostPosted: Sat Feb 28, 2015 3:30 pm    Post subject: Reply with quote

It went further, but still failed:

Code:

# LDFLAGS="-L/opt/vc/lib/" emerge kodi

...

CPP     xbmc/cores/dvdplayer/DVDPlayerVideo.o
In file included from /var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/windowing/X11/WinSystemX11.h:26:0,
                 from /var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/windowing/X11/WinSystemX11GLES.h:25,
                 from /var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/windowing/WindowingFactory.h:33,
                 from DVDPlayerVideo.cpp:23:
/var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/system_gl.h:51:27: fatal error: GLES2/gl2.h: No such file or directory
     #include <GLES2/gl2.h>
                           ^
compilation terminated.
/var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/Makefile.include:93: recipe for target 'DVDPlayerVideo.o' failed
make[1]: *** [DVDPlayerVideo.o] Error 1
Makefile:515: recipe for target 'xbmc/cores/dvdplayer/DVDPlayer.a' failed
make: *** [xbmc/cores/dvdplayer/DVDPlayer.a] Error 2
Back to top
View user's profile Send private message
Leio
Developer
Developer


Joined: 27 Feb 2003
Posts: 494
Location: Estonia

PostPosted: Tue Mar 03, 2015 2:22 pm    Post subject: Reply with quote

Sorry, been ill and away from the keyboard.
Maybe a dev-libs/libgpg-error dependency is missing (from main tree too)?
Regarding the gl2.h thing, it's probably what I suspected - need to have it find the headers via CPPFLAGS too.
I tweaked in some append-cppflags and append-ldflags in my overlay like I had done to webkit-gtk too earlier - please test with that after a sync of my overlay.

Oh, and noticed your note in #rpi-gentoo. Yes,making sure rpi-userland is chosen in eselect opengl might be beneficial.
Though I now noticed I have xorg-x11 as well again and hasn't really been a problem. I think it ought to only affect runtime, not building.
After further look, it looks like it might actually make the append-ldflags part unnecessary, but still better to have it, to not be dependent on the user setting; but I don't see it helping the error you are getting - finding headers. eselect opengl doesn't seem to link up EGL/GLES2 include paths yet, just full opengl I think, which rpi-userland doesn't provide.
I am sticking to an older eselect-opengl though, that doesn't force building against mesa headers always
_________________
GNOME team lead; GStreamer; MIPS/ARM64
Back to top
View user's profile Send private message
keet
Guru
Guru


Joined: 09 Sep 2008
Posts: 568

PostPosted: Fri Mar 06, 2015 2:54 am    Post subject: Reply with quote

Thank you for the update. It still fails at the same place (checking -lgpg-error) if I don't set LDFLAGS="-L/opt/vc/lib/" .

If I do set them, it fails to build whether I'm using xorg-x11 or raspberry-pi OpenGL. The most recent error is:

Code:

In file included from /usr/include/EGL/egl.h:36:0,
                 from /var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/windowing/X11/WinSystemX11.h:33,
                 from /var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/windowing/X11/WinSystemX11GLES.h:25,
                 from /var/tmp/portage/media-tv/kodi-14.1/work/xbmc-14.1-Helix/xbmc/windowing/WindowingFactory.h:33,
                 from ExternalPlayer.cpp:28:
/usr/include/EGL/eglplatform.h:110:45: fatal error: interface/vmcs_host/vc_dispmanx.h: No such file or directory
 #include "interface/vmcs_host/vc_dispmanx.h"
Back to top
View user's profile Send private message
Leio
Developer
Developer


Joined: 27 Feb 2003
Posts: 494
Location: Estonia

PostPosted: Fri Mar 06, 2015 5:23 am    Post subject: Reply with quote

Where are you getting /usr/include/EGL/* from?
_________________
GNOME team lead; GStreamer; MIPS/ARM64
Back to top
View user's profile Send private message
keet
Guru
Guru


Joined: 09 Sep 2008
Posts: 568

PostPosted: Sat Mar 07, 2015 4:40 am    Post subject: Reply with quote

It might just be that I'm very tired and working on several things at once, but I don't know. Qfile isn't showing anything for it, either.
Back to top
View user's profile Send private message
Leio
Developer
Developer


Joined: 27 Feb 2003
Posts: 494
Location: Estonia

PostPosted: Mon Mar 09, 2015 4:29 pm    Post subject: Reply with quote

it's probably symlinked up by eselect opengl when mesa is present. Try deleting them and going again.
Really need to figure out how to do this cleanly in packages (that those wouldn't disturb, etc), but I don't have time for that myself right now (most of the other work I actually do in my overlay is partially funded for a work project)
_________________
GNOME team lead; GStreamer; MIPS/ARM64
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum