test/configure.in
changeset 1380 d94b080ff6ce
parent 1367 e440d5c488c1
child 1387 835c1831f903
     1.1 --- a/test/configure.in	Sun Feb 19 23:46:34 2006 +0000
     1.2 +++ b/test/configure.in	Mon Feb 20 02:09:49 2006 +0000
     1.3 @@ -1,15 +1,10 @@
     1.4  dnl Process this file with autoconf to produce a configure script.
     1.5  AC_INIT(README)
     1.6  
     1.7 -dnl Setup for automake
     1.8 -SDL_VERSION=1.2.7
     1.9 -
    1.10  dnl Detect the canonical host and target build environment
    1.11 +AC_CONFIG_AUX_DIRS($srcdir/../build-scripts)
    1.12  AC_CANONICAL_SYSTEM
    1.13  
    1.14 -dnl Setup for automake
    1.15 -AM_INIT_AUTOMAKE(SDL_tests, $SDL_VERSION)
    1.16 -
    1.17  dnl Check for tools
    1.18  
    1.19  AC_PROG_CC
    1.20 @@ -18,29 +13,32 @@
    1.21  
    1.22  AC_C_CONST
    1.23  
    1.24 -FIXME: add math library for testsprite
    1.25 -
    1.26  dnl Figure out which math library to use
    1.27  case "$target" in
    1.28      *-*-cygwin* | *-*-mingw32*)
    1.29 +        EXE=".exe"
    1.30          MATHLIB=""
    1.31          SYS_GL_LIBS="-lopengl32"
    1.32          ;;
    1.33      *-*-beos*)
    1.34 +        EXE=""
    1.35          MATHLIB=""
    1.36          SYS_GL_LIBS="-lGL"
    1.37          ;;
    1.38      *-*-darwin* )
    1.39 +        EXE=""
    1.40          MATHLIB=""
    1.41          SYS_GL_LIBS=""
    1.42          ;;
    1.43      *-*-aix*)
    1.44 +        EXE=""
    1.45          if test x$ac_cv_prog_gcc = xyes; then
    1.46              CFLAGS="-mthreads"
    1.47          fi
    1.48          SYS_GL_LIBS=""
    1.49          ;;
    1.50      *-*-mint*)
    1.51 +        EXE=""
    1.52          MATHLIB=""
    1.53          AC_PATH_PROG(OSMESA_CONFIG, osmesa-config, no)
    1.54          if test "x$OSMESA_CONFIG" = "xyes"; then
    1.55 @@ -53,21 +51,16 @@
    1.56          fi
    1.57  		;;
    1.58      *)
    1.59 +        EXE=""
    1.60          MATHLIB="-lm"
    1.61 -        AC_PATH_X
    1.62 -        AC_PATH_XTRA
    1.63 -        if test x$have_x = xyes; then
    1.64 -            CFLAGS="$CFLAGS $X_CFLAGS"
    1.65 -            SYS_GL_LIBS="$X_LIBS -lGL"
    1.66 -        else
    1.67 -            SYS_GL_LIBS="-lGL"
    1.68 -        fi
    1.69 +        SYS_GL_LIBS="-lGL"
    1.70          ;;
    1.71  esac
    1.72 +AC_SUBST(EXE)
    1.73  AC_SUBST(MATHLIB)
    1.74  
    1.75  dnl Check for SDL
    1.76 -
    1.77 +SDL_VERSION=1.2.7
    1.78  AM_PATH_SDL($SDL_VERSION,
    1.79              :,
    1.80  	    AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!])
    1.81 @@ -87,11 +80,11 @@
    1.82  AC_MSG_RESULT($have_opengl)
    1.83  if test x$have_opengl = xyes; then
    1.84      CFLAGS="$CFLAGS -DHAVE_OPENGL"
    1.85 -    GL_LIBS="$SYS_GL_LIBS"
    1.86 +    GLLIB="$SYS_GL_LIBS"
    1.87  else
    1.88 -    GL_LIBS=""
    1.89 +    GLLIB=""
    1.90  fi
    1.91 -AC_SUBST(GL_LIBS)
    1.92 +AC_SUBST(GLLIB)
    1.93  
    1.94 -# Finally create all the generated files
    1.95 +dnl Finally create all the generated files
    1.96  AC_OUTPUT([Makefile])