[GLES] Problem with patch for GLES refactoring and new WinBindingEGL class
#1
Hallo,

i got a problem to link newer xmbc git versions.
I could now locate the problem versions before commit 323d2ec320c280e0c7565a1d0c110b9184d6e863
( https://github.com/xbmc/xbmc/commit/323d...9184d6e863 ) are working fine all versions after this commit (exact de0fe98632513600b7722988ecc17024cd67e164 , only a typo was fixed) don't pass ld anymore.

ld exits with this error message:

Code:
xbmc/utils/utils.a(GLUtils.o): In function `xbmcutil::GlobalsSingleton<CWinSystemGLES>::getQuick()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:176: undefined reference to `CWinSystemGLES::CWinSystemGLES()'
xbmc/utils/utils.a(GLUtils.o): In function `xbmcutil::GlobalsSingleton<CWinSystemGLES>::getInstance()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:160: undefined reference to `CWinSystemGLES::CWinSystemGLES()'
xbmc/utils/utils.a(Splash.o): In function `xbmcutil::GlobalsSingleton<CWinSystemGLES>::getQuick()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:176: undefined reference to `CWinSystemGLES::CWinSystemGLES()'
/root/xbmc/xbmc/utils/GlobalsHandling.h:176: undefined reference to `CWinSystemGLES::CWinSystemGLES()'
xbmc/utils/utils.a(Splash.o): In function `xbmcutil::GlobalsSingleton<CWinSystemGLES>::getInstance()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:160: undefined reference to `CWinSystemGLES::CWinSystemGLES()'
xbmc/utils/utils.a(SystemInfo.o):/root/xbmc/xbmc/utils/GlobalsHandling.h:176: more undefined references to `CWinSystemGLES::CWinSystemGLES()' follow
collect2: ld returned 1 exit status
make: *** [xbmc.bin] Error 1

configure options is ./configure --enable-ccache --enable-gles

does anybody else experience this problem?

original problem description and configure.log can be found here:
http://forum.xbmc.org/showthread.php?tid=110940

But since i know where the error come to the git and the problem is not pvr only i think this is the better place
Reply
#2
need to see your config.log

edit: make me run around to other threads and collect various bits of info Sad

panda is egl/gles/x11, it should be using WinSystemX11GLES and not WinSystemGLES which is for non-x11 platforms.

"/root/xbmc/xbmc/utils/GlobalsHandling.h:176: undefined reference to `CWinSystemGLES::CWinSystemGLES()'" means that xbmc/windowing/WindowingFactory.h picked "#include "egl/WinSystemGLES.h" instead of "#include "X11/WinSystemX11GLES.h", the big question is why ?

cd xbmc/windowing
V=1 make

I want to see the entire compile line.
Reply
#3
V=1 make can be found here:
http://pastebin.com/MNf1ax5W

i already tried to remove the checks and inlcude the WinSystemX11GLES and got this:
Code:
xbmc/utils/utils.a(GLUtils.o): In function `xbmcutil::GlobalsSingleton<CWinSystemX11GLES>::getQuick()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:175: undefined reference to `CWinSystemX11GLES::CWinSystemX11GLES()'
xbmc/utils/utils.a(GLUtils.o): In function `xbmcutil::GlobalsSingleton<CWinSystemX11GLES>::getInstance()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:159: undefined reference to `CWinSystemX11GLES::CWinSystemX11GLES()'
xbmc/utils/utils.a(Splash.o): In function `xbmcutil::GlobalsSingleton<CWinSystemX11GLES>::getQuick()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:175: undefined reference to `CWinSystemX11GLES::CWinSystemX11GLES()'
/root/xbmc/xbmc/utils/GlobalsHandling.h:175: undefined reference to `CWinSystemX11GLES::CWinSystemX11GLES()'
xbmc/utils/utils.a(Splash.o): In function `xbmcutil::GlobalsSingleton<CWinSystemX11GLES>::getInstance()':
/root/xbmc/xbmc/utils/GlobalsHandling.h:159: undefined reference to `CWinSystemX11GLES::CWinSystemX11GLES()'
xbmc/utils/utils.a(SystemInfo.o):/root/xbmc/xbmc/utils/GlobalsHandling.h:175: more undefined references to `CWinSystemX11GLES::CWinSystemX11GLES()' follow
collect2: ld returned 1 exit status
make: *** [xbmc.bin] Error 1
Reply
#4
edit xbmc/windowing/WindowingFactory.h and find which path it's taking.

you can do this by forcing a compile error. add 'crap;" after the include. The compile will barf as 'crap;' is not a valid c++ Smile

Also revert back to standard xbmc source code, since I have no clue what you changed, it will be impossible for me to figure out what's going on.
Reply
#5
ok, i am back in the clean xbmc,

this path is taken:
Code:
#elif defined(TARGET_LINUX)   && !defined(HAS_X11) && defined(HAS_GLES)
#include "egl/WinSystemGLES.h"

seems like HAS_X11 is not set properly
Reply
#6
hmm think this is a typo will change HAS_X11 to HAVE_X11 and try again

Code:
root@panda:/mnt/media/xbmc2# find . -print0 | xargs -0 grep -l "HAS_X11"
./xbmc/windowing/X11/WinSystemX11GLES.cpp
./xbmc/windowing/WindowingFactory.h
root@panda:/mnt/media/xbmc2# find . -print0 | xargs -0 grep -l "HAVE_X11"
./config.log
./lib/timidity/interface/x_sherry.c
./lib/timidity/interface/x_wrdwindow.c
./lib/timidity/interface/xaw_redef.c
./lib/timidity/config.h.in
./lib/timidity/configure.in
./lib/timidity/ChangeLog.2
./configure
./config.status
./xbmc/system.h
./xbmc/config.h
./xbmc/screensavers/rsxs-0.9/src/common.hh
./xbmc/screensavers/rsxs-0.9/configure
./xbmc/screensavers/rsxs-0.9/config.h.in
./xbmc/windowing/WindowingFactory.h
./xbmc/config.h.in
./configure.in
Reply
#7
yes, after many hours of searching, this little patch and everything went well
Code:
--- a/xbmc/windowing/WindowingFactory.h
+++ b/xbmc/windowing/WindowingFactory.h
@@ -33,10 +33,10 @@
#elif defined(TARGET_LINUX)   && defined(HAS_GLX)
#include "X11/WinSystemX11GL.h"

-#elif defined(TARGET_LINUX)   &&  defined(HAS_X11) && defined(HAS_GLES)
+#elif defined(TARGET_LINUX)   &&  defined(HAVE_X11) && defined(HAS_GLES)
#include "X11/WinSystemX11GLES.h"

-#elif defined(TARGET_LINUX)   && !defined(HAS_X11) && defined(HAS_GLES)
+#elif defined(TARGET_LINUX)   && !defined(HAVE_X11) && defined(HAS_GLES)
#include "egl/WinSystemGLES.h"

#elif defined(TARGET_DARWIN_OSX)
diff --git a/xbmc/windowing/X11/WinSystemX11GLES.cpp b/xbmc/windowing/X11/WinSystemX11GLES.cpp
index 23213f7..a94906d 100644
--- a/xbmc/windowing/X11/WinSystemX11GLES.cpp
+++ b/xbmc/windowing/X11/WinSystemX11GLES.cpp
@@ -20,7 +20,7 @@
  */
#include "system.h"

-#if defined(HAS_X11) && defined(HAS_GLES)
+#if defined(HAVE_X11) && defined(HAS_GLES)

#include "WinSystemX11GLES.h"
#include "utils/log.h"

ticket with patch http://trac.xbmc.org/ticket/12021
Reply
#8
Nice find, I'll trout slap the committer that made the HAS/HAVE mistake... oh wait Smile
Reply

Logout Mark Read Team Forum Stats Members Help
[GLES] Problem with patch for GLES refactoring and new WinBindingEGL class0