ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/Frodo4/Src/configure.ac
(Generate patch)

Comparing Frodo4/Src/configure.ac (file contents):
Revision 1.12 by cebix, 2010-04-21T19:55:45Z vs.
Revision 1.13 by cebix, 2010-04-23T11:12:05Z

# Line 1 | Line 1
1   dnl Process this file with autoconf to produce a configure script.
2  
3 < AC_INIT(Frodo, 4.2)
3 > AC_INIT([Frodo], [4.2])
4   AC_CONFIG_SRCDIR(main.cpp)
5   AC_PREREQ(2.52)
6   AC_CONFIG_HEADER(sysconfig.h)
# Line 13 | Line 13 | AC_PROG_MAKE_SET
13   AC_PROG_INSTALL
14   PKG_PROG_PKG_CONFIG
15  
16 + dnl Configure options.
17 + AC_ARG_ENABLE(opengl, [  --enable-opengl         use SDL/OpenGL for rendering [default=yes]], , enable_opengl=yes)
18 +
19   dnl -fomit-frame-pointer makes things faster
20   if [[ x"$GXX" = "xyes" ]]; then
21    CFLAGS="$CFLAGS -fomit-frame-pointer -fno-exceptions"
# Line 103 | Line 106 | elif [[ x"$HAVE_SDL" = "xyes" ]]; then
106    TARGET=sdl
107    CFLAGS="$CFLAGS $SDL_CFLAGS -DHAVE_SDL"
108    LIBS="$LIBS $SDL_LIBS"
109 +  if [[ "x$enable_opengl" = "xyes" ]]; then
110 +    AC_MSG_CHECKING(for OpenGL support)
111 +    have_opengl=no
112 +    AC_TRY_COMPILE([
113 +     #include <GL/glew.h>
114 +    ],[
115 +    ],[
116 +    have_opengl=yes
117 +    ])
118 +    AC_MSG_RESULT($have_opengl)
119 +    if test x$have_opengl = xyes; then
120 +      AC_DEFINE(ENABLE_OPENGL, 1, [OpenGL support is enabled])
121 +      LIBS="$LIBS -lGLEW"
122 +    else
123 +      AC_MSG_WARN([Could not find OpenGL, ignoring --enable-opengl.])
124 +    fi
125 +  fi
126   else
127    AC_MSG_RESULT([X Window System])
128    TARGET=x11

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines