Add configure options for MAX_WIDTH/HEIGHT.
authorTom Fogal <tfogal@alumni.unh.edu>
Fri, 14 Aug 2009 01:40:30 +0000 (19:40 -0600)
committerBrian Paul <brianp@vmware.com>
Fri, 14 Aug 2009 14:58:37 +0000 (08:58 -0600)
This adds two --with configure options for setting defines for
MAX_WIDTH and MAX_HEIGHT.  It's conceivably just as easy to define
these in CFLAGS manually, but this way users don't need to know
about internal Mesa details.

Patch updated by BrianP to set DEFINES, not CFLAGS.

configure.ac

index 9b65d96b3969ad64abac1552b445c23f764b3a77..9d318b3fc20062e79ac6aceaf2a6fda5c2db0631 100644 (file)
@@ -1159,6 +1159,21 @@ AC_ARG_WITH([xorg-driver-dir],
     [XORG_DRIVER_INSTALL_DIR="${libdir}/xorg/modules/drivers"])
 AC_SUBST([XORG_DRIVER_INSTALL_DIR])
 
+AC_ARG_WITH([max-width],
+    [AS_HELP_STRING([--with-max-width=N],
+                    [Maximum framebuffer width (4096)])],
+    [DEFINES="${DEFINES} -DMAX_WIDTH=${withval}";
+     AS_IF([test "${withval}" -gt "4096"],
+           [AC_MSG_WARN([Large framebuffer: see s_tritemp.h comments.])])]
+)
+AC_ARG_WITH([max-height],
+    [AS_HELP_STRING([--with-max-height=N],
+                    [Maximum framebuffer height (4096)])],
+    [DEFINES="${DEFINES} -DMAX_HEIGHT=${withval}";
+     AS_IF([test "${withval}" -gt "4096"],
+           [AC_MSG_WARN([Large framebuffer: see s_tritemp.h comments.])])]
+)
+
 dnl
 dnl Gallium Intel configuration
 dnl