Replaced 40 lines of silly shellscript code in configure with a pair of

nice and clean #ifdefs in glquake.h
This commit is contained in:
Marcus Sundberg 2000-05-31 22:53:07 +00:00
parent a087ac10b3
commit 1af69a110f
2 changed files with 9 additions and 15 deletions

View file

@ -366,21 +366,6 @@ if test "x$HAVE_GLX" != xno; then
AC_DEFINE(HAVE_GL_COLOR_INDEX8_EXT) AC_MSG_RESULT(yes),
AC_MSG_RESULT(no)
)
AC_MSG_CHECKING(for GLAPIENTRY in GL/gl.h)
AC_TRY_COMPILE(
[#include "GL/gl.h"],
[ int x = GLAPIENTRY printf("");],
AC_MSG_RESULT(yes)
,
AC_MSG_RESULT(no)
AC_MSG_CHECKING(for APIENTRY in GL/gl.h)
AC_TRY_COMPILE(
[#include "GL/gl.h"],
[ int x = APIENTRY printf("");],
AC_DEFINE(GLAPIENTRY, APIENTRY) AC_MSG_RESULT(yes),
AC_DEFINE(GLAPIENTRY, ) AC_MSG_RESULT(no)
)
)
fi
CPPFLAGS="$save_CPPFLAGS"

View file

@ -53,6 +53,15 @@
#include "wad.h"
#include "client.h"
#ifndef GLAPIENTRY
# ifdef APIENTRY
# define GLAPIENTRY APIENTRY
# else
# define GLAPIENTRY
# endif
#endif
void GL_BeginRendering (int *x, int *y, int *width, int *height);
void GL_EndRendering (void);