From bc3ece44c91b2c3d2a89abb247df359d4c2f44c8 Mon Sep 17 00:00:00 2001 From: dmiller Date: Thu, 7 Jan 2016 05:45:47 +0000 Subject: [PATCH] Check for Lua 5.2 instead of Lua >=5.2. Closes #259 --- configure | 7 ++++--- configure.ac | 5 +++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/configure b/configure index 335648146..fe8725bd9 100755 --- a/configure +++ b/configure @@ -6803,8 +6803,9 @@ ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lua version >= 502" >&5 -$as_echo_n "checking for lua version >= 502... " >&6; } + # We need Lua 5.2 exactly + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lua version == 502" >&5 +$as_echo_n "checking for lua version == 502... " >&6; } if test "$cross_compiling" = yes; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling -- assuming yes" >&5 @@ -6816,7 +6817,7 @@ else int main () { -if(LUA_VERSION_NUM < 502) return 1; +if(LUA_VERSION_NUM != 502) return 1; ; return 0; } diff --git a/configure.ac b/configure.ac index 8d5959bdb..0fc7e4822 100644 --- a/configure.ac +++ b/configure.ac @@ -642,10 +642,11 @@ else ) AC_LANG_PUSH(C++) - AC_MSG_CHECKING([for lua version >= 502]) + # We need Lua 5.2 exactly + AC_MSG_CHECKING([for lua version == 502]) AC_RUN_IFELSE([ AC_LANG_PROGRAM( [[#include ]], - [[if(LUA_VERSION_NUM < 502) return 1;]])], + [[if(LUA_VERSION_NUM != 502) return 1;]])], have_lua=yes, have_lua=no, AC_MSG_RESULT(cross-compiling -- assuming yes); have_lua=yes) AC_LANG_POP(C++)