sdl.m4
changeset 1550 31c2b8e4885e
parent 1118 65f4b2dd46b7
child 1659 14717b52abc0
equal deleted inserted replaced
1549:066236f0cbf0 1550:31c2b8e4885e
    30      if test x${SDL_CONFIG+set} != xset ; then
    30      if test x${SDL_CONFIG+set} != xset ; then
    31         SDL_CONFIG=$sdl_prefix/bin/sdl-config
    31         SDL_CONFIG=$sdl_prefix/bin/sdl-config
    32      fi
    32      fi
    33   fi
    33   fi
    34 
    34 
    35   AC_REQUIRE([AC_CANONICAL_TARGET])
       
    36   PATH="$prefix/bin:$prefix/usr/bin:$PATH"
    35   PATH="$prefix/bin:$prefix/usr/bin:$PATH"
    37   AC_PATH_PROG(SDL_CONFIG, sdl-config, no, [$PATH])
    36   AC_PATH_PROG(SDL_CONFIG, sdl-config, no, [$PATH])
    38   min_sdl_version=ifelse([$1], ,0.11.0,$1)
    37   min_sdl_version=ifelse([$1], ,0.11.0,$1)
    39   AC_MSG_CHECKING(for SDL - version >= $min_sdl_version)
    38   AC_MSG_CHECKING(for SDL - version >= $min_sdl_version)
    40   no_sdl=""
    39   no_sdl=""
   119     }
   118     }
   120 }
   119 }
   121 
   120 
   122 ],, no_sdl=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
   121 ],, no_sdl=yes,[echo $ac_n "cross compiling; assumed OK... $ac_c"])
   123        CFLAGS="$ac_save_CFLAGS"
   122        CFLAGS="$ac_save_CFLAGS"
       
   123        CXXFLAGS="$ac_save_CXXFLAGS"
   124        LIBS="$ac_save_LIBS"
   124        LIBS="$ac_save_LIBS"
   125      fi
   125      fi
   126   fi
   126   fi
   127   if test "x$no_sdl" = x ; then
   127   if test "x$no_sdl" = x ; then
   128      AC_MSG_RESULT(yes)
   128      AC_MSG_RESULT(yes)
   168           CXXFLAGS="$ac_save_CXXFLAGS"
   168           CXXFLAGS="$ac_save_CXXFLAGS"
   169           LIBS="$ac_save_LIBS"
   169           LIBS="$ac_save_LIBS"
   170        fi
   170        fi
   171      fi
   171      fi
   172      SDL_CFLAGS=""
   172      SDL_CFLAGS=""
   173      SDL_CXXFLAGS=""
       
   174      SDL_LIBS=""
   173      SDL_LIBS=""
   175      ifelse([$3], , :, [$3])
   174      ifelse([$3], , :, [$3])
   176   fi
   175   fi
   177   AC_SUBST(SDL_CFLAGS)
   176   AC_SUBST(SDL_CFLAGS)
   178   AC_SUBST(SDL_LIBS)
   177   AC_SUBST(SDL_LIBS)