diff options
author | Eric Anholt <eric@anholt.net> | 2008-04-18 15:03:01 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2008-04-18 15:04:21 -0700 |
commit | 711222bb7b4fd7ea8e7f801ac26532360bc5440f (patch) | |
tree | eb53e842f3d28a9d321b2b6def666848226e2f1c /configure.ac | |
parent | 27e06a52342b94b4fb1d60a57c3bdaa2b30607cf (diff) |
autoconf: Default the build to DRI on OS+CPU combos where it's expected.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index 7db1830af4..8566384e0c 100644 --- a/configure.ac +++ b/configure.ac @@ -237,11 +237,26 @@ dnl dnl Driver configuration. Options are xlib, dri and osmesa right now. dnl More later: directfb, fbdev, ... dnl +default_driver="xlib" + +case "$host_os" in +linux*) + case "$host_cpu" in + i*86|x86_64|powerpc*) default_driver="dri";; + esac + ;; +freebsd* | dragonfly*) + case "$host_cpu" in + i*86|x86_64) default_driver="dri";; + esac + ;; +esac + AC_ARG_WITH(driver, [AS_HELP_STRING([--with-driver=DRIVER], - [driver for Mesa: xlib,dri,osmesa @<:@default=xlib@:>@])], + [driver for Mesa: xlib,dri,osmesa @<:@default=dri when available, or xlib@:>@])], mesa_driver="$withval", - mesa_driver="xlib") + mesa_driver="$default_driver") dnl Check for valid option case "x$mesa_driver" in xxlib|xdri|xosmesa) |