Oops: fixed SDL header check: put flags in CPPFLAGS rather than CFLAGS.

Original commit message from CVS:
Oops: fixed SDL header check: put flags in CPPFLAGS rather than CFLAGS.
We should really filter the SDL_CFLAGS and only pass appropriate options
through, but this works well enough for now.
This commit is contained in:
Richard Boulton 2001-06-02 02:21:25 +00:00
parent 0c8050e3ba
commit 97b6de7b23

View file

@ -588,10 +588,12 @@ if sdl-config --libs > /dev/null 2>&1; then
SDL_CFLAGS="`sdl-config --cflags`"
AC_CHECK_LIB(SDL, SDL_Init, :, HAVE_LIBSDL=no, $SDL_LIBS)
dnl FIXME: CPPFLAGS should be set from SDL_CFLAGS for the next check
CFLAGS="$sdlcheck_save_CFLAGS"
CFLAGS="$CFLAGS $SDL_CFLAGS"
dnl AC_CHECK_HEADER uses CPPFLAGS, but not CFLAGS.
dnl Assume only suitable flags result from artsc-config --cflags
CPPFLAGS="$sdlcheck_save_CPPFLAGS"
CPPFLAGS="$CPPFLAGS $SDL_CFLAGS"
AC_CHECK_HEADER(SDL.h, :, HAVE_LIBSDL=no)
sdlcheck_save_CFLAGS="$CFLAGS"
sdlcheck_save_CPPFLAGS="$CPPFLAGS"
AC_CHECK_LIB(SDL, SDL_CreateYUVOverlay, :, HAVE_LIBSDL=no, $SDL_LIBS)
else
AC_MSG_RESULT(not found)