Skip to content

Commit

Permalink
Add EGL_NO_X11 define to avoid including X11. (KhronosGroup#90)
Browse files Browse the repository at this point in the history
This allows unix-based systems to not depend on X11 headers to define
EGLNative types, using primitive types instead.
  • Loading branch information
tomwardio authored and oddhack committed Oct 4, 2019
1 parent d1f084a commit 64c92f4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions EGL/eglplatform.h
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,12 @@ typedef intptr_t EGLNativeDisplayType;
typedef intptr_t EGLNativePixmapType;
typedef intptr_t EGLNativeWindowType;

#elif defined(__unix__) && defined(EGL_NO_X11)

typedef void *EGLNativeDisplayType;
typedef khronos_uintptr_t EGLNativePixmapType;
typedef khronos_uintptr_t EGLNativeWindowType;

#elif defined(__unix__) || defined(USE_X11)

/* X11 (tentative) */
Expand Down

0 comments on commit 64c92f4

Please # to comment.