diff options
author | Armin K <[email protected]> | 2013-11-09 00:06:45 +0100 |
---|---|---|
committer | Matt Turner <[email protected]> | 2013-11-09 09:12:46 -0800 |
commit | f0f202e6b764be803470e27cba9102f14361ae22 (patch) | |
tree | f6364fa9dbdd97425a3ad155833c3360ccba151e /src/glx | |
parent | 68349e52194b7eba521b88d42ee8db3bfdf0a877 (diff) |
glx: conditionaly build dri3 and present loader (v3)
This patch makes it possible to disable DRI3 if desired.
Tested with:
./configure --disable-dri3 --with-dri-drivers=i965 \
--with-gallium-drivers= --disable-vdpau --disable-egl \
--disable-gbm --disable-xvmc
Reviewed-by: Ian Romanick <[email protected]>
Reviewed-by: Matt Turner <[email protected]>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=71397
Cc: 10.0 <[email protected]>
Diffstat (limited to 'src/glx')
-rw-r--r-- | src/glx/Makefile.am | 8 | ||||
-rw-r--r-- | src/glx/glxext.c | 4 |
2 files changed, 10 insertions, 2 deletions
diff --git a/src/glx/Makefile.am b/src/glx/Makefile.am index ae296b92236..0aec2aa3daa 100644 --- a/src/glx/Makefile.am +++ b/src/glx/Makefile.am @@ -94,10 +94,14 @@ libglx_la_SOURCES = \ dri2_glx.c \ dri2.c \ dri2_query_renderer.c \ - dri3_glx.c \ - dri3_common.c \ applegl_glx.c +if HAVE_DRI3 +libglx_la_SOURCES += \ + dri3_glx.c \ + dri3_common.c +endif + GL_LIBS = \ libglx.la \ $(SHARED_GLAPI_LIBS) \ diff --git a/src/glx/glxext.c b/src/glx/glxext.c index c6e4d9f5738..2711e57b793 100644 --- a/src/glx/glxext.c +++ b/src/glx/glxext.c @@ -770,8 +770,10 @@ AllocAndFetchScreenConfigs(Display * dpy, struct glx_display * priv) for (i = 0; i < screens; i++, psc++) { psc = NULL; #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL) +#if defined(HAVE_DRI3) if (priv->dri3Display) psc = (*priv->dri3Display->createScreen) (i, priv); +#endif if (psc == NULL && priv->dri2Display) psc = (*priv->dri2Display->createScreen) (i, priv); if (psc == NULL && priv->driDisplay) @@ -865,8 +867,10 @@ __glXInitialize(Display * dpy) ** (e.g., those called in AllocAndFetchScreenConfigs). */ if (glx_direct && glx_accel) { +#if defined(HAVE_DRI3) if (!getenv("LIBGL_DRI3_DISABLE")) dpyPriv->dri3Display = dri3_create_display(dpy); +#endif dpyPriv->dri2Display = dri2CreateDisplay(dpy); dpyPriv->driDisplay = driCreateDisplay(dpy); } |