[Mesa-dev] [PATCH 4/6] gallium: Add a dumb drm/kms winsys backed swrast provider

Jon TURNEY jon.turney at dronecode.org.uk
Thu Jul 31 09:53:37 PDT 2014


On 24/07/2014 01:43, Emil Velikov wrote:
> From: Giovanni Campagna <gcampagna at src.gnome.org>
>
> Add a new winsys and target that can be used with a dri2 state tracker
> and loader instead of drisw. This allows to use gbm as a dri2/image
> loader and avoid the extra copy from the backbuffer to the shadow
> frontbuffer.
>
> The new driver is called "kms_swrast", and is loaded by gbm as a
> fallback, because it is only useful with the gbm platform (as no buffer
> sharing is possible)
>
> To force select the driver set the environment variable
> GBM_ALWAYS_SOFTWARE
>
> [Emil Velikov]
>   - Rebase on top of gallium megadriver.
>   - s/text/test/ in configure.ac (Spotted by Andreas Pokorny).
>   - Add scons support for winsys/sw/kms-dri and fix the build.
>   - Provide separate DriverAPI, due to different InitScreen hook.

Unfortunately, this seems to break my build.

I guess something like the attached is needed.

[1] http://tinderbox.x.org/builds/2014-07-31-0006/logs/mesa-mesa/#build


-------------- next part --------------
From fd1aaf61a9e4c50db26fc89d608c8ec164cadbcc Mon Sep 17 00:00:00 2001
From: Jon TURNEY <jon.turney at dronecode.org.uk>
Date: Thu, 31 Jul 2014 16:30:37 +0100
Subject: [PATCH] Fix build since 3b176c441b7ddc5f7d2f891da3f76cf3c1814ce1 for
 dri_platform=none hosts

Signed-off-by: Jon TURNEY <jon.turney at dronecode.org.uk>
---
 src/gallium/auxiliary/target-helpers/inline_drm_helper.h | 2 ++
 src/gallium/targets/dri/Makefile.am                      | 1 +
 2 files changed, 3 insertions(+)

diff --git a/src/gallium/auxiliary/target-helpers/inline_drm_helper.h b/src/gallium/auxiliary/target-helpers/inline_drm_helper.h
index 751ceb1..5d02da7 100644
--- a/src/gallium/auxiliary/target-helpers/inline_drm_helper.h
+++ b/src/gallium/auxiliary/target-helpers/inline_drm_helper.h
@@ -60,6 +60,7 @@ static char* driver_name = NULL;
 
 #if defined(GALLIUM_SOFTPIPE)
 #if defined(DRI_TARGET)
+#if defined(HAVE_LIBDRM)
 
 const __DRIextension **__driDriverGetExtensions_kms_swrast(void);
 
@@ -84,6 +85,7 @@ kms_swrast_create_screen(int fd)
 }
 #endif
 #endif
+#endif
 
 #if defined(GALLIUM_I915)
 #if defined(DRI_TARGET)
diff --git a/src/gallium/targets/dri/Makefile.am b/src/gallium/targets/dri/Makefile.am
index 65b0a32..a9b4d44 100644
--- a/src/gallium/targets/dri/Makefile.am
+++ b/src/gallium/targets/dri/Makefile.am
@@ -8,6 +8,7 @@ AM_CFLAGS = \
 	$(GALLIUM_TARGET_CFLAGS)
 
 AM_CPPFLAGS = \
+	$(DEFINES) \
 	-DDRI_TARGET \
 	-DGALLIUM_GALAHAD \
 	-DGALLIUM_NOOP \
-- 
1.8.5.5



More information about the mesa-dev mailing list