aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib
diff options
context:
space:
mode:
authork-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c>2013-01-27 23:51:05 +0000
committerk-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c>2013-01-27 23:51:05 +0000
commitc68fcc48207a7b23393a9bc07f72570de8fcef86 (patch)
tree4603f3a5d17496a6a49e67e56999aa6801833578 /src/lib
parent045356f498df75c1d87a56512d655e6fc9f77558 (diff)
downloadusdx-c68fcc48207a7b23393a9bc07f72570de8fcef86.tar.gz
usdx-c68fcc48207a7b23393a9bc07f72570de8fcef86.tar.xz
usdx-c68fcc48207a7b23393a9bc07f72570de8fcef86.zip
add version number treatment for lua. The headers still need fixes for version 5.2
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@2936 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/Lua/ULua.pas22
1 files changed, 10 insertions, 12 deletions
diff --git a/src/lib/Lua/ULua.pas b/src/lib/Lua/ULua.pas
index 1de48a3c..59161dde 100644
--- a/src/lib/Lua/ULua.pas
+++ b/src/lib/Lua/ULua.pas
@@ -1,7 +1,8 @@
unit ULua;
(*
- * A complete Pascal wrapper for Lua 5.1 DLL module.
+ * A complete Pascal wrapper for Lua DLL module.
+ * Version 5.1 or 5.2
*
* Created by Geo Massar, 2006
* Distributed as free/open source.
@@ -34,15 +35,12 @@ const
LuaDLL = 'lua5.1.dll';
{$ENDIF}
{$IFDEF UNIX}
-{$IFDEF DARWIN}
- LuaDLL = 'liblua.5.1.dylib';
- {$linklib liblua.5.1}
-{$ELSE}
- LuaDLL = lua_lib_name;
-{$ENDIF}
-{$ENDIF}
-{$IFDEF MACOS}
- SDLgfxLibName = 'lua5.1';
+ {$IFDEF DARWIN}
+ LuaDLL = 'liblua.dylib';
+ {$linklib liblua}
+ {$ELSE}
+ LuaDLL = lua_lib_name;
+ {$ENDIF}
{$ENDIF}
(* formats for Lua numbers *)
@@ -139,8 +137,8 @@ const
*)
const
- LUA_VERSION = 'Lua 5.1';
- LUA_VERSION_NUM = 501;
+ LUA_VERSION = 'Lua ' + LUA_VERSION_MAJOR + '.' + LUA_VERSION_MINOR;
+ LUA_VERSION_NUM = 100*(ord(LUA_VERSION_MAJOR) - ord('0')) + (ord(LUA_VERSION_MINOR) - ord('0'));
LUA_COPYRIGHT = 'Copyright (C) 1994-2006 Tecgraf, PUC-Rio';
LUA_AUTHORS = 'R. Ierusalimschy, L. H. de Figueiredo & W. Celes';