Check for sdl-config before calling it

Check whether sdl-config is available before calling it, otherwise
./configure triggers a warning:
    ./configure: 957: sdl-config: not found

If neither the .pc file not sdl-config are present, disable SDL support.

Signed-off-by: Loïc Minier <lool@dooz.org>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
This commit is contained in:
Loïc Minier 2010-01-28 21:15:18 +00:00 committed by Blue Swirl
parent 82617d7ce3
commit a0dfd8a415

7
configure vendored
View File

@ -997,9 +997,14 @@ fi
if $pkgconfig sdl --modversion >/dev/null 2>&1; then if $pkgconfig sdl --modversion >/dev/null 2>&1; then
sdlconfig="$pkgconfig sdl" sdlconfig="$pkgconfig sdl"
_sdlversion=`$sdlconfig --modversion 2>/dev/null | sed 's/[^0-9]//g'` _sdlversion=`$sdlconfig --modversion 2>/dev/null | sed 's/[^0-9]//g'`
else elif which sdl-config >/dev/null 2>&1; then
sdlconfig='sdl-config' sdlconfig='sdl-config'
_sdlversion=`$sdlconfig --version | sed 's/[^0-9]//g'` _sdlversion=`$sdlconfig --version | sed 's/[^0-9]//g'`
else
if test "$sdl" = "yes" ; then
feature_not_found "sdl"
fi
sdl=no
fi fi
sdl_too_old=no sdl_too_old=no