configure.in
changeset 9278 8900afb78a19
parent 9252 a11e8f6d82d1
child 9315 541f12d1edcd
equal deleted inserted replaced
9277:f0bd40782fc7 9278:8900afb78a19
  2128         AC_DEFINE(SDL_VIDEO_RENDER_OGL, 1, [ ])
  2128         AC_DEFINE(SDL_VIDEO_RENDER_OGL, 1, [ ])
  2129         SUMMARY_video="${SUMMARY_video} opengl"
  2129         SUMMARY_video="${SUMMARY_video} opengl"
  2130     fi
  2130     fi
  2131 }
  2131 }
  2132 
  2132 
       
  2133 CheckEmscriptenGLES()
       
  2134 {
       
  2135     if test x$enable_video = xyes -a x$enable_video_opengles = xyes; then
       
  2136         AC_MSG_CHECKING(for EGL support)
       
  2137         video_opengl_egl=no
       
  2138         AC_TRY_COMPILE([
       
  2139          #include <EGL/egl.h>
       
  2140         ],[
       
  2141         ],[
       
  2142         video_opengl_egl=yes
       
  2143         ])
       
  2144         AC_MSG_RESULT($video_opengl_egl)
       
  2145         if test x$video_opengl_egl = xyes; then
       
  2146             AC_DEFINE(SDL_VIDEO_OPENGL_EGL, 1, [ ])
       
  2147         fi
       
  2148 
       
  2149         AC_MSG_CHECKING(for OpenGL ES v2 headers)
       
  2150         video_opengles_v2=no
       
  2151         AC_TRY_COMPILE([
       
  2152          #include <GLES2/gl2.h>
       
  2153          #include <GLES2/gl2ext.h>
       
  2154         ],[
       
  2155         ],[
       
  2156         video_opengles_v2=yes
       
  2157         ])
       
  2158         AC_MSG_RESULT($video_opengles_v2)
       
  2159         if test x$video_opengles_v2 = xyes; then
       
  2160             AC_DEFINE(SDL_VIDEO_OPENGL_ES2, 1, [ ])
       
  2161             AC_DEFINE(SDL_VIDEO_RENDER_OGL_ES2, 1, [ ])
       
  2162             SUMMARY_video="${SUMMARY_video} opengl_es2"
       
  2163         fi
       
  2164     fi
       
  2165 }
       
  2166 
  2133 dnl See if we can use the new unified event interface in Linux 2.4
  2167 dnl See if we can use the new unified event interface in Linux 2.4
  2134 CheckInputEvents()
  2168 CheckInputEvents()
  2135 {
  2169 {
  2136     dnl Check for Linux 2.4 unified input event interface support
  2170     dnl Check for Linux 2.4 unified input event interface support
  2137         AC_MSG_CHECKING(for Linux 2.4 unified input interface)
  2171         AC_MSG_CHECKING(for Linux 2.4 unified input interface)
  3300         if test x$enable_filesystem = xyes; then
  3334         if test x$enable_filesystem = xyes; then
  3301             AC_DEFINE(SDL_FILESYSTEM_NACL, 1, [ ])
  3335             AC_DEFINE(SDL_FILESYSTEM_NACL, 1, [ ])
  3302             SOURCES="$SOURCES $srcdir/src/filesystem/nacl/*.c"
  3336             SOURCES="$SOURCES $srcdir/src/filesystem/nacl/*.c"
  3303             have_filesystem=yes
  3337             have_filesystem=yes
  3304         fi
  3338         fi
       
  3339         ;;
       
  3340     *-*-emscripten* )
       
  3341         if test x$enable_video = xyes; then
       
  3342             AC_DEFINE(SDL_VIDEO_DRIVER_EMSCRIPTEN, 1, [ ])
       
  3343             SOURCES="$SOURCES $srcdir/src/video/emscripten/*.c"
       
  3344             have_video=yes
       
  3345             SUMMARY_video="${SUMMARY_video} emscripten"
       
  3346         fi
       
  3347 
       
  3348         if test x$enable_audio = xyes; then
       
  3349             AC_DEFINE(SDL_AUDIO_DRIVER_EMSCRIPTEN, 1, [ ])
       
  3350             SOURCES="$SOURCES $srcdir/src/audio/emscripten/*.c"
       
  3351             have_audio=yes
       
  3352             SUMMARY_audio="${SUMMARY_audio} emscripten"
       
  3353         fi
       
  3354 
       
  3355         CheckVisibilityHidden
       
  3356         CheckDummyVideo
       
  3357         CheckDiskAudio
       
  3358         CheckDummyAudio
       
  3359         CheckDLOPEN
       
  3360         CheckClockGettime
       
  3361         CheckEmscriptenGLES
       
  3362 
       
  3363          # Set up files for the power library
       
  3364         if test x$enable_power = xyes; then
       
  3365             AC_DEFINE(SDL_POWER_EMSCRIPTEN, 1, [ ])
       
  3366             SOURCES="$SOURCES $srcdir/src/power/emscripten/*.c"
       
  3367             have_power=yes
       
  3368         fi
  3305         
  3369         
       
  3370         # Set up files for the power library
       
  3371         if test x$enable_joystick = xyes; then
       
  3372             AC_DEFINE(SDL_JOYSTICK_EMSCRIPTEN, 1, [ ])
       
  3373             SOURCES="$SOURCES $srcdir/src/joystick/emscripten/*.c"
       
  3374             have_joystick=yes
       
  3375         fi
       
  3376 
       
  3377         # Set up files for the filesystem library
       
  3378         if test x$enable_filesystem = xyes; then
       
  3379             AC_DEFINE(SDL_FILESYSTEM_EMSCRIPTEN, 1, [ ])
       
  3380             SOURCES="$SOURCES $srcdir/src/filesystem/emscripten/*.c"
       
  3381             have_filesystem=yes
       
  3382         fi
       
  3383         # Set up files for the timer library
       
  3384         if test x$enable_timers = xyes; then
       
  3385             AC_DEFINE(SDL_TIMER_UNIX, 1, [ ])
       
  3386             SOURCES="$SOURCES $srcdir/src/timer/unix/*.c"
       
  3387             have_timers=yes
       
  3388         fi
  3306         ;;
  3389         ;;
  3307     *)
  3390     *)
  3308         AC_MSG_ERROR([
  3391         AC_MSG_ERROR([
  3309 *** Unsupported host:  Please add to configure.in
  3392 *** Unsupported host:  Please add to configure.in
  3310         ])
  3393         ])