Преглед на файлове

package/mesa3d: always enable glx-direct if glx is enabled

Many applications that use GLX want to combine it with DRI3 to bypass
the X server and send GL commands directly to the graphics driver. This
is only available in mesa3d if glx-direct=true.

Up to now, we only enabled glx-direct when a DRI driver was enabled.
Historically, this is either because only DRI drivers had DRI3, or
because we didn't know better at the time. However, glx-direct is not
related to DRI drivers at all. Setting it for a DRI driver when there is
no GLX is effectively a NOP. Conversely, we also want to set it for
Gallium drivers when GLX is enabled, otherwise GLX-direct applications
don't work.

Note that glx-direct is only functional if glx=dri. If glx=xlib or
glx=gallium-xlib, GLX always goes through the X server so direct is not
possible (as far as we understand).

Set glx-direct=true unconditionally when GLX is selected. Remove it from
DRI drivers.

Reported-by: Howard Mitchell <hm@hmbedded.co.uk>
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Arnout Vandecappelle (Essensium/Mind) преди 3 години
родител
ревизия
6a51177af1
променени са 1 файла, в които са добавени 4 реда и са изтрити 2 реда
  1. 4 2
      package/mesa3d/mesa3d.mk

+ 4 - 2
package/mesa3d/mesa3d.mk

@@ -73,7 +73,10 @@ ifeq ($(BR2_PACKAGE_MESA3D_OPENGL_GLX),y)
 #  dri          : dri based GLX requires at least one DRI driver || dri based GLX requires shared-glapi
 #  xlib         : xlib conflicts with any dri driver
 #  gallium-xlib : Gallium-xlib based GLX requires at least one gallium driver || Gallium-xlib based GLX requires softpipe or llvmpipe || gallium-xlib conflicts with any dri driver.
-MESA3D_CONF_OPTS += -Dglx=dri
+# Always enable glx-direct; without it, amy GLX applications don't work.
+MESA3D_CONF_OPTS += \
+	-Dglx=dri \
+	-Dglx-direct=true
 ifeq ($(BR2_PACKAGE_MESA3D_NEEDS_XA),y)
 MESA3D_CONF_OPTS += -Dgallium-xa=enabled
 else
@@ -136,7 +139,6 @@ MESA3D_CONF_OPTS += \
 else
 MESA3D_CONF_OPTS += \
 	-Dshared-glapi=enabled \
-	-Dglx-direct=true \
 	-Ddri-drivers=$(subst $(space),$(comma),$(MESA3D_DRI_DRIVERS-y))
 endif