Nux

Code review comment for lp:~jaytaoko/nux/nux-linaro-rev518-merge

Revision history for this message
Alexandros Frantzis (afrantzis) wrote :

The branch fails to build for gles2. Here is a fix:

=== modified file 'NuxGraphics/GraphicsDisplayX11.cpp'
--- NuxGraphics/GraphicsDisplayX11.cpp 2012-01-03 03:10:54 +0000
+++ NuxGraphics/GraphicsDisplayX11.cpp 2012-01-05 12:58:20 +0000
@@ -64,7 +64,9 @@
     , m_X11Screen(0)
     , m_ParentWindow(0)
     , m_GLCtx(0)
+#ifndef NUX_OPENGLES_20
     , glx_window_(0)
+#endif
     , m_NumVideoModes(0)
     , m_BorderPixel(0)
     , _x11_major(0)

=== modified file 'tools/unity_support_test.c'
--- tools/unity_support_test.c 2011-11-24 16:45:23 +0000
+++ tools/unity_support_test.c 2012-01-05 13:12:19 +0000
@@ -721,21 +721,26 @@
   // Open a X11 connection and get the root window.
   display = XOpenDisplay (display_name);

+#ifndef NUX_OPENGLES_20
   // Before doing anything with GLX, check that it is supported on the system.
   Bool glx_supported = False;
   int dummy0, dummy1;
   if (display)
     glx_supported = glXQueryExtension(display, &dummy0, &dummy1);
-
- if (!display || !glx_supported) {
- if (!display)
- results.error = strdup ("unable to open display");
- else
- results.error = strdup ("GLX is not available on the system");
-
- // exit with 5, to tell "it's not an error we should cache"
- results.result = 5;
- }
+#endif
+
+ if (!display) {
+ results.error = strdup ("unable to open display");
+ // exit with 5, to tell "it's not an error we should cache"
+ results.result = 5;
+ }
+#ifndef NUX_OPENGLES_20
+ else if (!glx_supported) {
+ results.error = strdup ("GLX is not available on the system");
+ // exit with 5, to tell "it's not an error we should cache"
+ results.result = 5;
+ }
+#endif
   else
   {
     screen = DefaultScreen (display);

« Back to merge proposal