diff src/auto/configure @ 2320:966a5609669e vim73

Added Lua interfae. (Luis Carvalho)
author Bram Moolenaar <bram@vim.org>
date Wed, 14 Jul 2010 23:23:17 +0200
parents 543ea69d037f
children ad2889f48843
line wrap: on
line diff
--- a/src/auto/configure
+++ b/src/auto/configure
@@ -662,6 +662,12 @@ MZSCHEME_PRO
 MZSCHEME_OBJ
 MZSCHEME_SRC
 vi_cv_path_mzscheme
+LUA_CFLAGS
+LUA_LIBS
+LUA_PRO
+LUA_OBJ
+LUA_SRC
+vi_cv_path_lua
 compiledby
 dogvimdiff
 dovimdiff
@@ -742,6 +748,8 @@ with_features
 with_compiledby
 enable_xsmp
 enable_xsmp_interact
+enable_luainterp
+with_lua_prefix
 enable_mzschemeinterp
 with_plthome
 enable_perlinterp
@@ -1405,6 +1413,7 @@ Optional Features:
   --disable-selinux	  Don't check for SELinux support.
   --disable-xsmp          Disable XSMP session management
   --disable-xsmp-interact Disable XSMP interaction
+  --enable-luainterp      Include Lua interpreter.
   --enable-mzschemeinterp   Include MzScheme interpreter.
   --enable-perlinterp     Include Perl interpreter.
   --enable-pythoninterp   Include Python interpreter.
@@ -1446,6 +1455,7 @@ Optional Packages:
   --with-modified-by=NAME       name of who modified a release version
   --with-features=TYPE    tiny, small, normal, big or huge (default: normal)
   --with-compiledby=NAME  name to show in :version message
+  --with-lua-prefix=PFX   Prefix where Lua is installed.
   --with-plthome=PLTHOME   Use PLTHOME.
   --with-python-config-dir=PATH  Python's config directory
   --with-tclsh=PATH       which tclsh to use (default: tclsh8.0)
@@ -4562,6 +4572,145 @@ else
 $as_echo "yes" >&6; }
 fi
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-luainterp argument" >&5
+$as_echo_n "checking --enable-luainterp argument... " >&6; }
+# Check whether --enable-luainterp was given.
+if test "${enable_luainterp+set}" = set; then :
+  enableval=$enable_luainterp;
+else
+  enable_luainterp="no"
+fi
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_luainterp" >&5
+$as_echo "$enable_luainterp" >&6; }
+
+if test "$enable_luainterp" = "yes"; then
+
+
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking --with-lua-prefix argument" >&5
+$as_echo_n "checking --with-lua-prefix argument... " >&6; }
+
+# Check whether --with-lua_prefix was given.
+if test "${with_lua_prefix+set}" = set; then :
+  withval=$with_lua_prefix; with_lua_prefix="$withval"; { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_lua_prefix" >&5
+$as_echo "$with_lua_prefix" >&6; }
+else
+  with_lua_prefix="";{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"no\"" >&5
+$as_echo "\"no\"" >&6; }
+fi
+
+
+  if test "X$with_lua_prefix" != "X"; then
+       vi_cv_path_lua_pfx="$with_lua_prefix"
+  else
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking LUA_PREFIX environment var" >&5
+$as_echo_n "checking LUA_PREFIX environment var... " >&6; }
+    if test "X$LUA_PREFIX" != "X"; then
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$LUA_PREFIX\"" >&5
+$as_echo "\"$LUA_PREFIX\"" >&6; }
+	vi_cv_path_lua_pfx="$LUA_PREFIX"
+    else
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"not set\"" >&5
+$as_echo "\"not set\"" >&6; }
+    fi
+  fi
+
+  LUA_INC=
+  if test "X$vi_cv_path_lua_pfx" != "X"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include" >&5
+$as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include... " >&6; }
+    if test -f $vi_cv_path_lua_pfx/include/lua.h; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"yes\"" >&5
+$as_echo "\"yes\"" >&6; }
+    else
+      { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"no\"" >&5
+$as_echo "\"no\"" >&6; }
+            # Extract the first word of "lua", so it can be a program name with args.
+set dummy lua; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_vi_cv_path_lua+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $vi_cv_path_lua in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_vi_cv_path_lua="$vi_cv_path_lua" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_path_vi_cv_path_lua="$as_dir/$ac_word$ac_exec_ext"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+  ;;
+esac
+fi
+vi_cv_path_lua=$ac_cv_path_vi_cv_path_lua
+if test -n "$vi_cv_path_lua"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_path_lua" >&5
+$as_echo "$vi_cv_path_lua" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+      if test "X$vi_cv_path_lua" != "X"; then
+                { $as_echo "$as_me:${as_lineno-$LINENO}: checking Lua version" >&5
+$as_echo_n "checking Lua version... " >&6; }
+if test "${vi_cv_version_lua+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+   vi_cv_version_lua=`${vi_cv_path_lua} -e "print(_VERSION:sub(5,7))"`
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $vi_cv_version_lua" >&5
+$as_echo "$vi_cv_version_lua" >&6; }
+        { $as_echo "$as_me:${as_lineno-$LINENO}: checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua" >&5
+$as_echo_n "checking if lua.h can be found in $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua... " >&6; }
+        if test -f $vi_cv_path_lua_pfx/include/lua$vi_cv_version_lua/lua.h; then
+          { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"yes\"" >&5
+$as_echo "\"yes\"" >&6; }
+          LUA_INC=/lua$vi_cv_version_lua
+        else
+          { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"no\"" >&5
+$as_echo "\"no\"" >&6; }
+          vi_cv_path_lua_pfx=
+        fi
+      fi
+    fi
+  fi
+
+  if test "X$vi_cv_path_lua_pfx" != "X"; then
+    if test "X$vi_cv_version_lua" != "X"; then
+            LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua$vi_cv_version_lua"
+    else
+      LUA_LIBS="-L${vi_cv_path_lua_pfx}/lib -llua"
+    fi
+    LUA_CFLAGS="-I${vi_cv_path_lua_pfx}/include${LUA_INC}"
+    LUA_SRC="if_lua.c"
+    LUA_OBJ="objects/if_lua.o"
+    LUA_PRO="if_lua.pro"
+    $as_echo "#define FEAT_LUA 1" >>confdefs.h
+
+  fi
+
+
+
+
+
+fi
+
+
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking --enable-mzschemeinterp argument" >&5
 $as_echo_n "checking --enable-mzschemeinterp argument... " >&6; }
 # Check whether --enable-mzschemeinterp was given.