Building LUA socket module or using Lua5.1 dll

Announcements, questions
Post Reply
docgyver
Posts: 1
Joined: 25 Apr 2018, 16:45

Building LUA socket module or using Lua5.1 dll

Post by docgyver » 25 Apr 2018, 17:08

I am trying to get some fairly accurate press/release timing and it looks like the solution is using the luasocket module.

I've tried using dlls built for lua5.1 and LMC tries to load it (yay it does support modules! :) but fails likely b/c LMC uses lua5.2 dll.

I'm wondering if I can replace the 5.2 dll in the luamacros folder with a 5.1 dll. In addtion to asking here I will experiment with it but a definite "no" here will save me some time. :D
Has anyone tried to use version 5.1 of the LUA dll files?

Alternatively I want to build the module myself. I've started installing luarocks LuaRocks but it needs a compiler. Was figuring I would try mingw but am unsure about 32 or 64 bit. Figure it is 32 but again confirmation would be helpful.

A really nice alternative would be someone telling me they have a pre-build dll binary for luasocket which works with luamacros.

I'll update as soon as I've tried the 5.1 dlls.

TIA..

admin
Site Admin
Posts: 735
Joined: 01 Nov 2010, 13:00
Location: Prague, Czech republic
Contact:

Re: Building LUA socket module or using Lua5.1 dll

Post by admin » 26 Apr 2018, 08:22

My opinion is that you would need pascal headers for lua libraries with version 5.1 - to be able just to replace dlls.
Lmc now uses headers for 5.2 - file: https://github.com/me2d13/luamacros/blo ... ua/lua.pas
I googled a bit, found http://lua-users.org/wiki/LuaInFreePascal and it seems there's version for 5.2, 5.3 and 5.4.
So maybe you might be luckier with recompiling lua module to version 5.2+ - as suggested.
Petr Medek
LUAmacros author

Post Reply