aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/LuaJIT-1.1.7/etc
diff options
context:
space:
mode:
authorDavid Walter Seikel2012-01-23 23:36:30 +1000
committerDavid Walter Seikel2012-01-23 23:36:30 +1000
commit6523585c66c04cea54df50013df8886b589847d8 (patch)
tree0b22aee7064166d88595eda260ca2d17c0773da5 /libraries/LuaJIT-1.1.7/etc
parentUpdate the EFL to what I'm actually using, coz I'm using some stuff not yet r... (diff)
downloadSledjHamr-6523585c66c04cea54df50013df8886b589847d8.zip
SledjHamr-6523585c66c04cea54df50013df8886b589847d8.tar.gz
SledjHamr-6523585c66c04cea54df50013df8886b589847d8.tar.bz2
SledjHamr-6523585c66c04cea54df50013df8886b589847d8.tar.xz
Add luaproc and LuaJIT libraries.
Two versions of LuaJIT, the stable release, and the dev version. Try the dev version first, until ih fails badly.
Diffstat (limited to 'libraries/LuaJIT-1.1.7/etc')
-rw-r--r--libraries/LuaJIT-1.1.7/etc/README20
-rw-r--r--libraries/LuaJIT-1.1.7/etc/lua.hpp9
-rw-r--r--libraries/LuaJIT-1.1.7/etc/luajit.icobin0 -> 1078 bytes
-rw-r--r--libraries/LuaJIT-1.1.7/etc/luajit.pc28
-rwxr-xr-xlibraries/LuaJIT-1.1.7/etc/luavs.bat22
-rw-r--r--libraries/LuaJIT-1.1.7/etc/strict.lua41
6 files changed, 120 insertions, 0 deletions
diff --git a/libraries/LuaJIT-1.1.7/etc/README b/libraries/LuaJIT-1.1.7/etc/README
new file mode 100644
index 0000000..98117d0
--- /dev/null
+++ b/libraries/LuaJIT-1.1.7/etc/README
@@ -0,0 +1,20 @@
1This directory contains some useful files and code.
2Unlike the code in ../src, everything here is in the public domain.
3
4lua.hpp
5 Lua header files for C++ using 'extern "C"'.
6
7luajit.ico
8 A LuaJIT icon for Windows (and web sites: save as favicon.ico).
9 Lua icon drawn by hand by Markus Gritsch. Modified for LuaJIT.
10
11luajit.pc
12 pkg-config data for LuaJIT
13
14luavs.bat
15 Script to build LuaJIT under "Visual Studio .NET Command Prompt".
16 Run it from the toplevel as etc\luavs.bat.
17
18strict.lua
19 Traps uses of undeclared global variables.
20
diff --git a/libraries/LuaJIT-1.1.7/etc/lua.hpp b/libraries/LuaJIT-1.1.7/etc/lua.hpp
new file mode 100644
index 0000000..ec417f5
--- /dev/null
+++ b/libraries/LuaJIT-1.1.7/etc/lua.hpp
@@ -0,0 +1,9 @@
1// lua.hpp
2// Lua header files for C++
3// <<extern "C">> not supplied automatically because Lua also compiles as C++
4
5extern "C" {
6#include "lua.h"
7#include "lualib.h"
8#include "lauxlib.h"
9}
diff --git a/libraries/LuaJIT-1.1.7/etc/luajit.ico b/libraries/LuaJIT-1.1.7/etc/luajit.ico
new file mode 100644
index 0000000..bdd7a90
--- /dev/null
+++ b/libraries/LuaJIT-1.1.7/etc/luajit.ico
Binary files differ
diff --git a/libraries/LuaJIT-1.1.7/etc/luajit.pc b/libraries/LuaJIT-1.1.7/etc/luajit.pc
new file mode 100644
index 0000000..1444076
--- /dev/null
+++ b/libraries/LuaJIT-1.1.7/etc/luajit.pc
@@ -0,0 +1,28 @@
1# luajit.pc -- pkg-config data for LuaJIT
2
3# vars from install Makefile
4
5# grep '^J*V=' ../Makefile
6V= 5.1
7JV= 1.1.7
8
9# grep '^INSTALL_.*=' ../Makefile | sed 's/INSTALL_TOP/prefix/'
10prefix= /usr/local
11INSTALL_BIN= ${prefix}/bin
12INSTALL_INC= ${prefix}/include
13INSTALL_LIB= ${prefix}/lib
14INSTALL_MAN= ${prefix}/man/man1
15INSTALL_LMOD= ${prefix}/share/lua/${V}
16INSTALL_CMOD= ${prefix}/lib/lua/${V}
17
18exec_prefix=${prefix}
19libdir=${exec_prefix}/lib
20includedir=${prefix}/include
21
22Name: LuaJIT
23Description: An Extensible Extension Language (JIT compiled for speed)
24Version: ${JV}
25Requires:
26Libs: -L${libdir} -llua -lm
27Cflags: -I${includedir}
28
diff --git a/libraries/LuaJIT-1.1.7/etc/luavs.bat b/libraries/LuaJIT-1.1.7/etc/luavs.bat
new file mode 100755
index 0000000..4f311e2
--- /dev/null
+++ b/libraries/LuaJIT-1.1.7/etc/luavs.bat
@@ -0,0 +1,22 @@
1@rem Script to build LuaJIT under "Visual Studio .NET Command Prompt".
2@rem Do not run from this directory; run it from the toplevel: etc\luavs.bat .
3@rem It creates lua51.dll, lua51.lib and luajit.exe in src.
4@rem (contributed by David Manura and Mike Pall)
5
6@setlocal
7@set MYCOMPILE=cl /nologo /MD /O2 /W3 /c /D_CRT_SECURE_NO_DEPRECATE /I . /I ..\dynasm
8@set MYLINK=link /nologo
9@set MYMT=mt /nologo
10
11cd src
12%MYCOMPILE% /DLUA_BUILD_AS_DLL l*.c
13del lua.obj luac.obj
14%MYLINK% /DLL /out:lua51.dll l*.obj
15if exist lua51.dll.manifest^
16 %MYMT% -manifest lua51.dll.manifest -outputresource:lua51.dll;2
17%MYCOMPILE% /DLUA_BUILD_AS_DLL lua.c
18%MYLINK% /out:luajit.exe lua.obj lua51.lib
19if exist luajit.exe.manifest^
20 %MYMT% -manifest luajit.exe.manifest -outputresource:luajit.exe
21del *.obj *.manifest
22cd ..
diff --git a/libraries/LuaJIT-1.1.7/etc/strict.lua b/libraries/LuaJIT-1.1.7/etc/strict.lua
new file mode 100644
index 0000000..604619d
--- /dev/null
+++ b/libraries/LuaJIT-1.1.7/etc/strict.lua
@@ -0,0 +1,41 @@
1--
2-- strict.lua
3-- checks uses of undeclared global variables
4-- All global variables must be 'declared' through a regular assignment
5-- (even assigning nil will do) in a main chunk before being used
6-- anywhere or assigned to inside a function.
7--
8
9local getinfo, error, rawset, rawget = debug.getinfo, error, rawset, rawget
10
11local mt = getmetatable(_G)
12if mt == nil then
13 mt = {}
14 setmetatable(_G, mt)
15end
16
17mt.__declared = {}
18
19local function what ()
20 local d = getinfo(3, "S")
21 return d and d.what or "C"
22end
23
24mt.__newindex = function (t, n, v)
25 if not mt.__declared[n] then
26 local w = what()
27 if w ~= "main" and w ~= "C" then
28 error("assign to undeclared variable '"..n.."'", 2)
29 end
30 mt.__declared[n] = true
31 end
32 rawset(t, n, v)
33end
34
35mt.__index = function (t, n)
36 if not mt.__declared[n] and what() ~= "C" then
37 error("variable '"..n.."' is not declared", 2)
38 end
39 return rawget(t, n)
40end
41