summaryrefslogtreecommitdiff
path: root/src/egl
diff options
context:
space:
mode:
authorChia-I Wu <olv@lunarg.com>2010-06-17 16:07:46 +0800
committerChia-I Wu <olv@lunarg.com>2010-06-17 16:30:26 +0800
commitda39d5d3b46c55f88a2f051368e09284732fd440 (patch)
tree024068049ecc3fd110f981cec8c051d701a5c076 /src/egl
parent6f690caddcd9afbea6ed3e743b0c95c02c85e5ef (diff)
egl: s/EGL_DISPLAY/EGL_PLATFORM/.
A platform is already used to mean a window system in EGL. No need to use a different term.
Diffstat (limited to 'src/egl')
-rw-r--r--src/egl/main/Makefile6
-rw-r--r--src/egl/main/egldriver.c19
2 files changed, 14 insertions, 11 deletions
diff --git a/src/egl/main/Makefile b/src/egl/main/Makefile
index 0af964d874..d9e9e4fcd6 100644
--- a/src/egl/main/Makefile
+++ b/src/egl/main/Makefile
@@ -7,7 +7,7 @@ include $(TOP)/configs/current
EGL_MAJOR = 1
EGL_MINOR = 0
-INCLUDE_DIRS = -I$(TOP)/include $(X11_CFLAGS)
+INCLUDE_DIRS = -I$(TOP)/include
HEADERS = \
eglcompiler.h \
@@ -51,10 +51,10 @@ OBJECTS = $(SOURCES:.c=.o)
# use dl*() to load drivers
LOCAL_CFLAGS = -D_EGL_OS_UNIX=1
-EGL_DEFAULT_DISPLAY = $(word 1, $(EGL_DISPLAYS))
+EGL_DEFAULT_PLATFORM = $(firstword $(EGL_PLATFORMS))
LOCAL_CFLAGS += \
- -D_EGL_DEFAULT_DISPLAY=\"$(EGL_DEFAULT_DISPLAY)\" \
+ -D_EGL_DEFAULT_PLATFORM=\"$(EGL_DEFAULT_PLATFORM)\" \
-D_EGL_DRIVER_SEARCH_DIR=\"$(EGL_DRIVER_INSTALL_DIR)\"
.c.o:
diff --git a/src/egl/main/egldriver.c b/src/egl/main/egldriver.c
index ce5f0f22f0..f56214472e 100644
--- a/src/egl/main/egldriver.c
+++ b/src/egl/main/egldriver.c
@@ -464,24 +464,27 @@ _eglPreloadUserDriver(void)
/**
- * Preload display drivers.
+ * Preload platform drivers.
*
- * Display drivers are a set of drivers that support a certain display system.
- * The display system may be specified by EGL_DISPLAY.
+ * Platform drivers are a set of drivers that support a certain window system.
+ * The window system may be specified by EGL_PLATFORM.
*
* FIXME This makes libEGL a memory hog if an user driver is not specified and
- * there are many display drivers.
+ * there are many platform drivers.
*/
static EGLBoolean
-_eglPreloadDisplayDrivers(void)
+_eglPreloadPlatformDrivers(void)
{
const char *dpy;
char prefix[32];
int ret;
- dpy = getenv("EGL_DISPLAY");
+ dpy = getenv("EGL_PLATFORM");
+ /* try deprecated env variable */
if (!dpy || !dpy[0])
- dpy = _EGL_DEFAULT_DISPLAY;
+ dpy = getenv("EGL_DISPLAY");
+ if (!dpy || !dpy[0])
+ dpy = _EGL_DEFAULT_PLATFORM;
if (!dpy || !dpy[0])
return EGL_FALSE;
@@ -515,7 +518,7 @@ _eglPreloadDrivers(void)
}
loaded = (_eglPreloadUserDriver() ||
- _eglPreloadDisplayDrivers());
+ _eglPreloadPlatformDrivers());
_eglUnlockMutex(_eglGlobal.Mutex);