From bd953fdd549310638b6960f358b31a40c05ca680 Mon Sep 17 00:00:00 2001 From: Jonathan White Date: Wed, 6 Aug 2008 16:37:49 -0600 Subject: [PATCH] egl: fixes for Windows --- src/egl/main/egldriver.c | 5 ++++- src/egl/main/egllog.c | 4 ++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/egl/main/egldriver.c b/src/egl/main/egldriver.c index f5edb58f433..43b1f519034 100644 --- a/src/egl/main/egldriver.c +++ b/src/egl/main/egldriver.c @@ -146,10 +146,12 @@ _eglChooseDriver(_EGLDisplay *dpy) (void) DefaultDriverName; +#if defined(_EGL_PLATFORM_X) /* First, if the EGL_DRIVER env var is set, use that */ driverName = getenv("EGL_DRIVER"); if (driverName) return _eglstrdup(driverName); +#endif #if 0 if (!displayString) { @@ -217,7 +219,8 @@ _eglOpenDriver(_EGLDisplay *dpy, const char *driverName, const char *args) #if defined(_EGL_PLATFORM_WINDOWS) /* Use static linking on Windows for now */ -#ifdef WINDOWS_STATIC_LINK +#ifdef WINDOWS_STATIC_LINK + lib = 0; mainFunc = (_EGLMain_t)_eglMain; #else /* XXX untested */ diff --git a/src/egl/main/egllog.c b/src/egl/main/egllog.c index 23eb523eebe..1d7a0a388c6 100644 --- a/src/egl/main/egllog.c +++ b/src/egl/main/egllog.c @@ -21,7 +21,11 @@ static EGLint ReportingLevel = -1; static void log_level_initialize(void) { +#if defined(_EGL_PLATFORM_X) char *log_env = getenv("EGL_LOG_LEVEL"); +#else + char *log_env = NULL; +#endif if (log_env == NULL) { ReportingLevel = FALLBACK_LOG_LEVEL; -- 2.30.2