From 665b8d89dcb12f7c60b6366dfba9d6c1acfb4328 Mon Sep 17 00:00:00 2001 From: Ozkan Sezer Date: Sun, 20 Dec 2020 03:00:04 +0300 Subject: tests: update acinclude.m4 from top-level sdl.m4 ... had been outdated for quite some time. --- test/acinclude.m4 | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/test/acinclude.m4 b/test/acinclude.m4 index b6df43f08..0a61b613a 100644 --- a/test/acinclude.m4 +++ b/test/acinclude.m4 @@ -20,34 +20,36 @@ AC_ARG_ENABLE(sdltest, [ --disable-sdltest Do not try to compile and run , enable_sdltest=yes) if test x$sdl_exec_prefix != x ; then - sdl_args="$sdl_args --exec-prefix=$sdl_exec_prefix" + sdl_config_args="$sdl_config_args --exec-prefix=$sdl_exec_prefix" if test x${SDL_CONFIG+set} != xset ; then SDL_CONFIG=$sdl_exec_prefix/bin/sdl-config fi fi if test x$sdl_prefix != x ; then - sdl_args="$sdl_args --prefix=$sdl_prefix" + sdl_config_args="$sdl_config_args --prefix=$sdl_prefix" if test x${SDL_CONFIG+set} != xset ; then SDL_CONFIG=$sdl_prefix/bin/sdl-config fi fi - if test "x$prefix" != xNONE; then + as_save_PATH="$PATH" + if test "x$prefix" != xNONE && test "$cross_compiling" != yes; then PATH="$prefix/bin:$prefix/usr/bin:$PATH" fi AC_PATH_PROG(SDL_CONFIG, sdl-config, no, [$PATH]) - min_sdl_version=ifelse([$1], ,0.11.0,$1) + PATH="$as_save_PATH" + min_sdl_version=ifelse([$1], ,1.2.0,$1) AC_MSG_CHECKING(for SDL - version >= $min_sdl_version) no_sdl="" if test "$SDL_CONFIG" = "no" ; then no_sdl=yes else - SDL_CFLAGS=`$SDL_CONFIG $sdlconf_args --cflags` - SDL_LIBS=`$SDL_CONFIG $sdlconf_args --libs` + SDL_CFLAGS=`$SDL_CONFIG $sdl_config_args --cflags` + SDL_LIBS=`$SDL_CONFIG $sdl_config_args --libs` - sdl_major_version=`$SDL_CONFIG $sdl_args --version | \ + sdl_major_version=`$SDL_CONFIG $sdl_config_args --version | \ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\1/'` - sdl_minor_version=`$SDL_CONFIG $sdl_args --version | \ + sdl_minor_version=`$SDL_CONFIG $sdl_config_args --version | \ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\2/'` sdl_micro_version=`$SDL_CONFIG $sdl_config_args --version | \ sed 's/\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\)/\3/'` -- cgit v1.2.1