Is there a way to create a standalone executable from simple lua scripts? simple i mean: i just use what lua 5.1 provides.
if so, is there some kind of "cross-compiler"? I would like to create binaries for the linux system on my mac osx system.
early!
You can execute Lua executables with chmod +xand add #!/usr/bin/env lua. But you will need to install a Lua interpreter. For a different approach, see srlua .
chmod +x
#!/usr/bin/env lua
murgaLua squish lua 1 ( ).
"" .
, lua, lua, (, , ).
, script .
lua2bin ( ), lua script c , .
try using Lua bin2c, which will give you the C source code of your lua script. If you use external lua libraries, it might be a little harder to take off, but squishing can help with that. Or you can just luaL_loadstring all
LuaJIT 2.0.4 was released on 2015-05-14(I use it on debian based linux (Crunchbang)
http://luajit.org
$ luajit -v LuaJIT 2.0.4 -- Copyright (C) 2005-2015 Mike Pall. http://luajit.org/ $ luajit -e 'print(_VERSION)' Lua 5.1
(put this at the top of your script) #! / usr / bin / env luajit
Source: https://habr.com/ru/post/1780639/More articles:How to check if Flash is installed? - androidHow can I fix this "missing, before statement" error in javascript? - javascriptAssembly Language: + vs add - assemblyКак определить фактическое тело и получателей SMS с MFMessageComposeViewController для iPhone? - iphoneTemplating Language, such as Smarty, available for dotnet - c #How to enable authentication for Mercurial push / pull operation when using TortoiseHg? - dvcsRegular expression to clear XML - xmlHow to create a custom table for a dating site? - phpИспользование script в автоматизированном процессе сборки - powershellиспользование веб-службы с аутентификацией всегда дает сообщение Требуется аутентификация - web-servicesAll Articles