st/mesa: fix pipe_get_transfer() call in fallback_copy_texsubimage()
[mesa.git] / configure.ac
index 249a68937cc44903b28825f12c2953278d58d40a..c36b2f6459ee1c66d242215931f75f1b11d049c8 100644 (file)
@@ -559,6 +559,13 @@ AC_ARG_ENABLE([gallium_egl],
          @<:@default=disable@:>@])],
     [enable_gallium_egl="$enableval"],
     [enable_gallium_egl=no])
+AC_ARG_ENABLE([gallium_gbm],
+    [AS_HELP_STRING([--enable-gallium-gbm],
+        [enable optional gbm state tracker (not required for
+         gbm support in Gallium)
+         @<:@default=disable@:>@])],
+    [enable_gallium_gbm="$enableval"],
+    [enable_gallium_gbm=no])
 
 # Option for Gallium drivers
 GALLIUM_DRIVERS_DEFAULT="r300,r600,swrast"
@@ -1300,10 +1307,26 @@ if test "x$enable_gallium_egl" = xyes; then
     fi
 
     GALLIUM_STATE_TRACKERS_DIRS="egl $GALLIUM_STATE_TRACKERS_DIRS"
-    GALLIUM_TARGET_DIRS="$GALLIUM_TARGET_DIRS egl"
+    GALLIUM_TARGET_DIRS="$GALLIUM_TARGET_DIRS egl-static"
     HAVE_ST_EGL="yes"
 fi
 
+dnl
+dnl gbm Gallium configuration
+dnl
+if test "x$enable_gallium_gbm" = xyes; then
+    if test "x$with_gallium_drivers" = x; then
+        AC_MSG_ERROR([cannot enable gbm_gallium without Gallium])
+    fi
+    if test "x$enable_gbm" = xno; then
+        AC_MSG_ERROR([cannot enable gbm_gallium without gbm])
+    fi
+
+    GALLIUM_STATE_TRACKERS_DIRS="gbm $GALLIUM_STATE_TRACKERS_DIRS"
+    GALLIUM_TARGET_DIRS="$GALLIUM_TARGET_DIRS gbm"
+    HAVE_ST_GBM="yes"
+fi
+
 dnl
 dnl X.Org DDX configuration
 dnl
@@ -1607,9 +1630,6 @@ case "$with_egl_platforms" in
 yes)
     if test "x$enable_egl" = xyes && test "x$mesa_driver" != xosmesa; then
         EGL_PLATFORMS="x11"
-        if test "$mesa_driver" = dri; then
-            EGL_PLATFORMS="$EGL_PLATFORMS drm"
-        fi
     fi
     ;;
 *)
@@ -1630,6 +1650,9 @@ yes)
                WAYLAND_EGL_LIB_DEPS="$WAYLAND_LIBS $LIBDRM_LIBS"
                 GALLIUM_WINSYS_DIRS="$GALLIUM_WINSYS_DIRS sw/wayland"
        fi
+        if test "$plat" = "drm" && test "x$enable_gbm" = no; then
+                AC_MSG_ERROR([EGL platform drm needs gbm])
+        fi
     done
     EGL_PLATFORMS="$egl_platforms"
     ;;