summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Boll <andreas.boll.dev@gmail.com>2015-12-10 15:40:44 +0100
committerAndreas Boll <andreas.boll.dev@gmail.com>2016-01-21 15:25:23 +0100
commit2e693775c38caca6d9a31620523448973563ce04 (patch)
treeb970677705eee9170e646df6d0184f9dbaddbfd2
parent1815f0bb6e1a20dcc768bc69f4e94aa76c42539f (diff)
downloadmesa-demos-2e693775c38caca6d9a31620523448973563ce04.zip
mesa-demos-2e693775c38caca6d9a31620523448973563ce04.tar.xz
configure.ac: Fix default behavior of AC_ARG_WITH(glut) if glut isn't available
Fixes a regression introduced in 406248811eb0dfabf75ae9495b54529ec59cce66 It wrongly sets glut_enabled=yes if glut isn't available and neither option --with-glut nor --without-glut was given. The default behavior in that case should be if glut is available then enable glut else it should disable glut. To fix this the default value of glut_enabled is set back to yes and in case --without-glut was given glut_enabled is set to no. Cc: Ross Burton <ross.burton@intel.com> Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com>
-rw-r--r--configure.ac7
1 files changed, 3 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac
index 0525b09..ddc68b5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -67,7 +67,7 @@ DEMO_CFLAGS="$DEMO_CFLAGS $GL_CFLAGS"
DEMO_LIBS="$DEMO_LIBS $GL_LIBS"
dnl Check for GLUT
-glut_enabled=no
+glut_enabled=yes
AC_ARG_WITH([glut],
[AS_HELP_STRING([--with-glut=DIR],
[glut install directory])],
@@ -83,9 +83,8 @@ AS_IF([test "x$with_glut" != xno],
AC_CHECK_LIB([glut],
[glutInit],
[],
- [glut_enabled=no])
- glut_enabled=yes
-])
+ [glut_enabled=no])],
+ [glut_enabled=no])
dnl Check for FreeGLUT 2.6 or later
AC_EGREP_HEADER([glutInitContextProfile],