Mesa (master): pipe-loader: conditionally build and use pipe_loader_sw_probe_dri
Emil Velikov
evelikov at kemper.freedesktop.org
Fri Apr 25 20:10:17 UTC 2014
Module: Mesa
Branch: master
Commit: 5c6a1445d530d5c070d1c5288dddf59884c7fca8
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=5c6a1445d530d5c070d1c5288dddf59884c7fca8
Author: Emil Velikov <emil.l.velikov at gmail.com>
Date: Tue Apr 1 17:42:40 2014 +0100
pipe-loader: conditionally build and use pipe_loader_sw_probe_dri
The function relies on the sw/dri winsys which is build only when --enable-dri
is set. Fixes build issues with the following config
./configure --disable-dri --with-gallium-drivers=svga --enable-xa
Issue can be reproduced with any hw gallium driver + st that uses the pipe-loader.
Cc: Brian Paul <brianp at vmware.com>
Reported-by: Brian Paul <brianp at vmware.com>
Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
configure.ac | 4 ++++
src/gallium/auxiliary/pipe-loader/pipe_loader.h | 4 ++++
src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c | 2 ++
3 files changed, 10 insertions(+)
diff --git a/configure.ac b/configure.ac
index c71fa26..b18f8cc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1941,6 +1941,10 @@ if test "x$enable_gallium_loader" = xyes; then
GALLIUM_PIPE_LOADER_DEFINES="$GALLIUM_PIPE_LOADER_DEFINES -DHAVE_PIPE_LOADER_XLIB"
fi
+ if test "x$enable_dri" = xyes; then
+ GALLIUM_PIPE_LOADER_DEFINES="$GALLIUM_PIPE_LOADER_DEFINES -DHAVE_PIPE_LOADER_DRI"
+ fi
+
if test "x$enable_gallium_drm_loader" = xyes; then
GALLIUM_PIPE_LOADER_DEFINES="$GALLIUM_PIPE_LOADER_DEFINES -DHAVE_PIPE_LOADER_DRM"
PKG_CHECK_MODULES([GALLIUM_PIPE_LOADER_XCB], [xcb xcb-dri2],
diff --git a/src/gallium/auxiliary/pipe-loader/pipe_loader.h b/src/gallium/auxiliary/pipe-loader/pipe_loader.h
index a5e49fc..caef6c1 100644
--- a/src/gallium/auxiliary/pipe-loader/pipe_loader.h
+++ b/src/gallium/auxiliary/pipe-loader/pipe_loader.h
@@ -119,6 +119,9 @@ pipe_loader_sw_probe_xlib(struct pipe_loader_device **devs, Display *display);
#endif
+
+#ifdef HAVE_PIPE_LOADER_DRI
+
/**
* Initialize sw dri device give the drisw_loader_funcs.
*
@@ -130,6 +133,7 @@ bool
pipe_loader_sw_probe_dri(struct pipe_loader_device **devs,
struct drisw_loader_funcs *drisw_lf);
+#endif
/**
* Initialize a null sw device.
diff --git a/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c b/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
index 35ec37f..08d4353 100644
--- a/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
+++ b/src/gallium/auxiliary/pipe-loader/pipe_loader_sw.c
@@ -75,6 +75,7 @@ pipe_loader_sw_probe_xlib(struct pipe_loader_device **devs, Display *display)
}
#endif
+#ifdef HAVE_PIPE_LOADER_DRI
bool
pipe_loader_sw_probe_dri(struct pipe_loader_device **devs, struct drisw_loader_funcs *drisw_lf)
{
@@ -95,6 +96,7 @@ pipe_loader_sw_probe_dri(struct pipe_loader_device **devs, struct drisw_loader_f
return true;
}
+#endif
bool
pipe_loader_sw_probe_null(struct pipe_loader_device **devs)
More information about the mesa-commit
mailing list