mirror of https://github.com/encounter/SDL.git
Merge commit 'e5821bf27668a5e54c699743c2b97aa55e7bdd93' into main
This commit is contained in:
commit
4fa42cab7f
|
@ -22431,7 +22431,47 @@ $as_echo "#define SDL_VIDEO_OPENGL_GLX 1" >>confdefs.h
|
|||
|
||||
$as_echo "#define SDL_VIDEO_RENDER_OGL 1" >>confdefs.h
|
||||
|
||||
SUMMARY_video="${SUMMARY_video} opengl"
|
||||
SUMMARY_video="${SUMMARY_video} opengl(glx)"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
CheckOpenGLKMSDRM()
|
||||
{
|
||||
if test x$enable_video = xyes -a x$enable_video_opengl = xyes -a x$enable_video_kmsdrm = xyes; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenGL (GLVND) support" >&5
|
||||
$as_echo_n "checking for OpenGL (GLVND) support... " >&6; }
|
||||
video_opengl=no
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
#include <GL/gl.h>
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
|
||||
video_opengl=yes
|
||||
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $video_opengl" >&5
|
||||
$as_echo "$video_opengl" >&6; }
|
||||
if test x$video_opengl = xyes; then
|
||||
|
||||
$as_echo "#define SDL_VIDEO_OPENGL 1" >>confdefs.h
|
||||
|
||||
|
||||
$as_echo "#define SDL_VIDEO_RENDER_OGL 1" >>confdefs.h
|
||||
|
||||
SUMMARY_video="${SUMMARY_video} opengl(glvnd)"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
@ -25040,6 +25080,7 @@ $as_echo "#define SDL_VIDEO_DRIVER_ANDROID 1" >>confdefs.h
|
|||
# Need to check for EGL first because KMSDRM depends on it.
|
||||
CheckEGLKMSDRM
|
||||
CheckKMSDRM
|
||||
CheckOpenGLKMSDRM
|
||||
CheckOpenGLX11
|
||||
CheckOpenGLESX11
|
||||
CheckVulkan
|
||||
|
|
|
@ -1442,48 +1442,6 @@ fi
|
|||
|
||||
} # ac_fn_c_try_compile
|
||||
|
||||
# ac_fn_c_try_run LINENO
|
||||
# ----------------------
|
||||
# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
|
||||
# that executables *can* be run.
|
||||
ac_fn_c_try_run ()
|
||||
{
|
||||
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
|
||||
if { { ac_try="$ac_link"
|
||||
case "(($ac_try" in
|
||||
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
||||
*) ac_try_echo=$ac_try;;
|
||||
esac
|
||||
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
|
||||
$as_echo "$ac_try_echo"; } >&5
|
||||
(eval "$ac_link") 2>&5
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
|
||||
{ { case "(($ac_try" in
|
||||
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
||||
*) ac_try_echo=$ac_try;;
|
||||
esac
|
||||
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
|
||||
$as_echo "$ac_try_echo"; } >&5
|
||||
(eval "$ac_try") 2>&5
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; }; }; then :
|
||||
ac_retval=0
|
||||
else
|
||||
$as_echo "$as_me: program exited with status $ac_status" >&5
|
||||
$as_echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
ac_retval=$ac_status
|
||||
fi
|
||||
rm -rf conftest.dSYM conftest_ipa8_conftest.oo
|
||||
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
|
||||
as_fn_set_status $ac_retval
|
||||
|
||||
} # ac_fn_c_try_run
|
||||
|
||||
# ac_fn_c_try_link LINENO
|
||||
# -----------------------
|
||||
# Try to link conftest.$ac_ext, and return whether this succeeded.
|
||||
|
@ -1530,6 +1488,48 @@ fi
|
|||
|
||||
} # ac_fn_c_try_link
|
||||
|
||||
# ac_fn_c_try_run LINENO
|
||||
# ----------------------
|
||||
# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
|
||||
# that executables *can* be run.
|
||||
ac_fn_c_try_run ()
|
||||
{
|
||||
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
|
||||
if { { ac_try="$ac_link"
|
||||
case "(($ac_try" in
|
||||
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
||||
*) ac_try_echo=$ac_try;;
|
||||
esac
|
||||
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
|
||||
$as_echo "$ac_try_echo"; } >&5
|
||||
(eval "$ac_link") 2>&5
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
|
||||
{ { case "(($ac_try" in
|
||||
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
|
||||
*) ac_try_echo=$ac_try;;
|
||||
esac
|
||||
eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
|
||||
$as_echo "$ac_try_echo"; } >&5
|
||||
(eval "$ac_try") 2>&5
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; }; }; then :
|
||||
ac_retval=0
|
||||
else
|
||||
$as_echo "$as_me: program exited with status $ac_status" >&5
|
||||
$as_echo "$as_me: failed program was:" >&5
|
||||
sed 's/^/| /' conftest.$ac_ext >&5
|
||||
|
||||
ac_retval=$ac_status
|
||||
fi
|
||||
rm -rf conftest.dSYM conftest_ipa8_conftest.oo
|
||||
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
|
||||
as_fn_set_status $ac_retval
|
||||
|
||||
} # ac_fn_c_try_run
|
||||
|
||||
# ac_fn_c_try_cpp LINENO
|
||||
# ----------------------
|
||||
# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
|
||||
|
@ -2996,7 +2996,53 @@ fi
|
|||
ISUNIX="true"
|
||||
EXE=""
|
||||
MATHLIB="-lm"
|
||||
have_glvnd=no
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glBegin in -lOpenGL" >&5
|
||||
$as_echo_n "checking for glBegin in -lOpenGL... " >&6; }
|
||||
if ${ac_cv_lib_OpenGL_glBegin+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
ac_check_lib_save_LIBS=$LIBS
|
||||
LIBS="-lOpenGL $LIBS"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
/* Override any GCC internal prototype to avoid an error.
|
||||
Use char because int might match the return type of a GCC
|
||||
builtin and then its argument prototype would still apply. */
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
char glBegin ();
|
||||
int
|
||||
main ()
|
||||
{
|
||||
return glBegin ();
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_link "$LINENO"; then :
|
||||
ac_cv_lib_OpenGL_glBegin=yes
|
||||
else
|
||||
ac_cv_lib_OpenGL_glBegin=no
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
LIBS=$ac_check_lib_save_LIBS
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_OpenGL_glBegin" >&5
|
||||
$as_echo "$ac_cv_lib_OpenGL_glBegin" >&6; }
|
||||
if test "x$ac_cv_lib_OpenGL_glBegin" = xyes; then :
|
||||
|
||||
SYS_GL_LIBS="-lOpenGL"
|
||||
|
||||
else
|
||||
|
||||
SYS_GL_LIBS="-lGL"
|
||||
|
||||
fi
|
||||
|
||||
;;
|
||||
esac
|
||||
|
||||
|
|
Loading…
Reference in New Issue