diff options
Diffstat (limited to 'src/lua/README')
| -rw-r--r-- | src/lua/README | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/src/lua/README b/src/lua/README deleted file mode 100644 index 525f6c15..00000000 --- a/src/lua/README +++ /dev/null @@ -1,41 +0,0 @@ -This is lua, the stand-alone Lua interpreter. -It can be used as a batch interpreter and also interactively. -There are man pages for it in both nroff and html in ../../doc. - -Usage: lua [options] [script [args]]. Available options are: - - execute stdin as a file - -e stat execute string `stat' - -i enter interactive mode after executing `script' - -l name load and run library `name' - -v show version information - -w catch use of undefined global variables - -- stop handling options - -This interpreter is suitable for using Lua as a stand-alone language; it loads -all standard libraries. For a minimal interpreter, see ../../etc/min.c. - -If your application simply exports new functions to Lua (which is common), -then you can use this interpreter unmodified by putting your functions into -a library and loading it dynamically (if you have built support for dynamic -libraries). - -If you need to add your library statically, then you can use this interpreter -almost unmodified, as follows: - -* First, define a function - void myinit (lua_State *L) - in your own code. In this function, you should do whatever initializations - are needed by your application, typically exporting your functions to Lua. - (Of course, you can use any name instead of "myinit".) - -* Then, #define lua_userinit(L) in luaconf.h to call luaopen_stdlibs and - possibly luaopen_stdlibs, which opens all standard libraries. If you don't - need them, just don't call openstdlibs and open any standard libraries that - you do need in myinit. - -* Alternatively, write your own luaopen_stdlibs; the linker will use your - version (if you ask politely). - -Just remember to link your C code when building lua! - -For other customizations, see ../../include/luaconf.h . |
