aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure21
1 files changed, 11 insertions, 10 deletions
diff --git a/configure b/configure
index 4a5542b9..8e1ce94c 100755
--- a/configure
+++ b/configure
@@ -187,7 +187,8 @@ search_interpreter() {
187 then 187 then
188 if detect_lua_version "$lua_at/$name" 188 if detect_lua_version "$lua_at/$name"
189 then 189 then
190 echo "Lua interpreter found: $(GREEN "$lua_at/$name")" 190 LUA="$lua_at/$name"
191 echo "Lua interpreter found: $(GREEN "$LUA")"
191 if [ "$LUA_BINDIR_SET" != "yes" ] 192 if [ "$LUA_BINDIR_SET" != "yes" ]
192 then 193 then
193 LUA_BINDIR="$lua_at" 194 LUA_BINDIR="$lua_at"
@@ -196,7 +197,7 @@ search_interpreter() {
196 then 197 then
197 LUA_DIR=$(dirname "$lua_at") 198 LUA_DIR=$(dirname "$lua_at")
198 fi 199 fi
199 LUA_INTERPRETER="$name" 200
200 return 0 201 return 0
201 fi 202 fi
202 fi 203 fi
@@ -288,8 +289,8 @@ do
288 ;; 289 ;;
289 --with-lua-interpreter) 290 --with-lua-interpreter)
290 [ -n "$value" ] || die "Missing value in flag $key." 291 [ -n "$value" ] || die "Missing value in flag $key."
291 LUA_INTERPRETER="$value" 292 LUA_EXE="$value"
292 LUA_INTERPRETER_SET=yes 293 LUA_EXE_SET=yes
293 ;; 294 ;;
294 295
295 # For specialized uses of LuaRocks: 296 # For specialized uses of LuaRocks:
@@ -366,9 +367,9 @@ case "$LUA_VERSION" in
366 ;; 367 ;;
367esac 368esac
368 369
369if [ "$LUA_INTERPRETER_SET" = "yes" ] 370if [ "$LUA_EXE_SET" = "yes" ]
370then 371then
371 names="$LUA_INTERPRETER" 372 names="$LUA_EXE"
372fi 373fi
373 374
374for name in $names 375for name in $names
@@ -400,8 +401,8 @@ fi
400 401
401if [ "$LUA_VERSION_SET" = "yes" ] 402if [ "$LUA_VERSION_SET" = "yes" ]
402then 403then
403 echo_n "Checking if $LUA_BINDIR/$LUA_INTERPRETER is Lua version $LUA_VERSION... " 404 echo_n "Checking if $LUA is Lua version $LUA_VERSION... "
404 if detect_lua_version "$LUA_BINDIR/$LUA_INTERPRETER" 405 if detect_lua_version "$LUA"
405 then 406 then
406 echo "yes" 407 echo "yes"
407 else 408 else
@@ -433,7 +434,7 @@ check_incdir() {
433 "$incdir/lua-$LUA_VERSION/lua.h" \ 434 "$incdir/lua-$LUA_VERSION/lua.h" \
434 "$incdir/lua$(echo "$LUA_VERSION" | tr -d .)/lua.h" \ 435 "$incdir/lua$(echo "$LUA_VERSION" | tr -d .)/lua.h" \
435 "$incdir/lua.h" \ 436 "$incdir/lua.h" \
436 $("$LUA_BINDIR/$LUA_INTERPRETER" -e 'print(jit and [['"$incdir"'/luajit-]]..jit.version:match("(%d+%.%d+)")..[[/lua.h]] or "")') 437 $("$LUA" -e 'print(jit and [['"$incdir"'/luajit-]]..jit.version:match("(%d+%.%d+)")..[[/lua.h]] or "")')
437 do 438 do
438 if [ -f "$lua_h" ] 439 if [ -f "$lua_h" ]
439 then 440 then
@@ -485,7 +486,7 @@ prefix=$prefix
485sysconfdir=$sysconfdir 486sysconfdir=$sysconfdir
486rocks_tree=$rocks_tree 487rocks_tree=$rocks_tree
487LUA_VERSION=$LUA_VERSION 488LUA_VERSION=$LUA_VERSION
488LUA_INTERPRETER=$LUA_INTERPRETER 489LUA=$LUA
489LUA_DIR=$LUA_DIR 490LUA_DIR=$LUA_DIR
490LUA_BINDIR=$LUA_BINDIR 491LUA_BINDIR=$LUA_BINDIR
491LUA_INCDIR=$LUA_INCDIR 492LUA_INCDIR=$LUA_INCDIR