diff options
author | Carlo Marcelo Arenas Belón <carenas@gmail.com> | 2019-07-10 15:55:28 -0700 |
---|---|---|
committer | Laurent Vivier <laurent@vivier.eu> | 2019-08-21 10:31:33 +0200 |
commit | aee8a61946750b627f3b58438314a62be60dad34 (patch) | |
tree | 7491c95004f84c1107c6fc92484b7b917a591a5d | |
parent | edd318b7a3c54321ead363ffc1e22ebac5785f1d (diff) | |
download | qemu-aee8a61946750b627f3b58438314a62be60dad34.zip qemu-aee8a61946750b627f3b58438314a62be60dad34.tar.gz qemu-aee8a61946750b627f3b58438314a62be60dad34.tar.bz2 |
configure: fix sdl detection using sdl2-config
If SDL2 is requested but pkg-config doesn't have a module for it
configure should fallback to use sdl*-config, but wasn't able to
because and old variable (from SDL) was being used by mistake.
Correct the variable name and complete other related changes so
there are no more references to the old SDL.
Fixes: 0015ca5cbabe ("ui: remove support for SDL1.2 in favour of SDL2")
Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20190710225528.409-1-carenas@gmail.com>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
-rwxr-xr-x | configure | 9 |
1 files changed, 4 insertions, 5 deletions
@@ -3022,15 +3022,15 @@ fi ########################################## # SDL probe -# Look for sdl configuration program (pkg-config or sdl-config). Try -# sdl-config even without cross prefix, and favour pkg-config over sdl-config. +# Look for sdl configuration program (pkg-config or sdl2-config). Try +# sdl2-config even without cross prefix, and favour pkg-config over sdl2-config. sdl_probe () { if $pkg_config sdl2 --exists; then sdlconfig="$pkg_config sdl2" sdlversion=$($sdlconfig --modversion 2>/dev/null) - elif has ${sdl_config}; then + elif has "$sdl2_config"; then sdlconfig="$sdl2_config" sdlversion=$($sdlconfig --version) else @@ -3041,7 +3041,7 @@ sdl_probe () # no need to do the rest return fi - if test -n "$cross_prefix" && test "$(basename "$sdlconfig")" = sdl-config; then + if test -n "$cross_prefix" && test "$(basename "$sdlconfig")" = sdl2-config; then echo warning: using "\"$sdlconfig\"" to detect cross-compiled sdl >&2 fi @@ -8023,7 +8023,6 @@ preserve_env PKG_CONFIG preserve_env PKG_CONFIG_LIBDIR preserve_env PKG_CONFIG_PATH preserve_env PYTHON -preserve_env SDL_CONFIG preserve_env SDL2_CONFIG preserve_env SMBD preserve_env STRIP |