configure.in
上传用户:sun1608
上传日期:2007-02-02
资源大小:6116k
文件大小:2k
源码类别:

流媒体/Mpeg4/MP4

开发平台:

Visual C++

  1. dnl Process this file with autoconf to produce a configure script.
  2. AC_INIT(README)
  3. dnl Setup for automake
  4. SDL_VERSION=1.2.3
  5. dnl Detect the canonical host and target build environment
  6. AC_CANONICAL_HOST
  7. AC_CANONICAL_TARGET
  8. dnl Setup for automake
  9. AM_INIT_AUTOMAKE(SDL_tests, $SDL_VERSION)
  10. dnl Check for tools
  11. AC_PROG_CC
  12. dnl Check for compiler environment
  13. AC_C_CONST
  14. dnl Figure out which math library to use
  15. case "$target" in
  16.     *-*-cygwin* | *-*-mingw32*)
  17.         MATHLIB=""
  18.         SYS_GL_LIBS="-lopengl32"
  19.         ;;
  20.     *-*-beos*)
  21.         MATHLIB=""
  22.         SYS_GL_LIBS="-lGL"
  23.         ;;
  24.     *-*-darwin*)
  25.         MATHLIB=""
  26.         SYS_GL_LIBS=""
  27.         ;;
  28.     *-*-aix*)
  29.         if test x$ac_cv_prog_gcc = xyes; then
  30.             CFLAGS="-mthreads"
  31. fi
  32.         SYS_GL_LIBS=""
  33.         ;;
  34.     *)
  35.         MATHLIB="-lm"
  36.         AC_PATH_X
  37.         AC_PATH_XTRA
  38.         if test x$have_x = xyes; then
  39.             CFLAGS="$CFLAGS $X_CFLAGS"
  40.             SYS_GL_LIBS="$X_LIBS -lGL"
  41.         else
  42.             SYS_GL_LIBS="-lGL"
  43.         fi
  44.         ;;
  45. esac
  46. AC_SUBST(MATHLIB)
  47. dnl Check for SDL
  48. AM_PATH_SDL($SDL_VERSION,
  49.             :,
  50.     AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!])
  51. )
  52. CFLAGS="$CFLAGS $SDL_CFLAGS"
  53. LIBS="$LIBS $SDL_LIBS"
  54. dnl Check for OpenGL
  55. AC_MSG_CHECKING(for OpenGL support)
  56. have_opengl=no
  57. AC_TRY_COMPILE([
  58.  #include "SDL_opengl.h"
  59. ],[
  60. ],[
  61. have_opengl=yes
  62. ])
  63. AC_MSG_RESULT($have_opengl)
  64. if test x$have_opengl = xyes; then
  65.     CFLAGS="$CFLAGS -DHAVE_OPENGL"
  66.     GL_LIBS="$SYS_GL_LIBS"
  67. else
  68.     GL_LIBS=""
  69. fi
  70. AC_SUBST(GL_LIBS)
  71. # Finally create all the generated files
  72. AC_OUTPUT([Makefile])