ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > FARR Plugins and Aliases

FLua: FARR Plugins Using Lua

<< < (2/3) > >>

ewemoa:
Do you know if FLua can use external libraries from lua ?
-ecaradec (July 04, 2010, 05:21 AM)
--- End quote ---
Depending on what you mean, I think it may be doable (perhaps in more than one way).

See:

  http://lua-users.org/wiki/BindingCodeToLua

Specifically, some bits I'm thinking of trying include:

  http://alien.luaforge.net/
  http://www.nongnu.org/cinvoke/lua.html

Thank you so much !

--- End quote ---
Thank you for FScript and its source :)

BTW, the DLL is built using Code::Blocks and MinGW.  I'm hoping to clean up the source and make it generally available before too long.

ewemoa:
Specifically, some bits I'm thinking of trying include:
  http://alien.luaforge.net/
-ewemoa (July 04, 2010, 07:12 AM)
--- End quote ---
I've been trying to get alien to work with FLua but haven't had much luck so far.  Actually, it looks more like some kind of problem building alien (or libffi which alien uses) using Code::Blocks / MinGW.  Compilation is successful but when trying to do something as simple as:


--- Code: Text ---require('alien')mb = alien.User32.MessageBoxAmb:types({ret = "long", abi = "stdcall", "long", "string", "string", "long"})mb(0, "Hey!", "From Lua", 0)
The host application (whether it's FARR of lua.exe) crashes at line 4 :(

ecaradec:
Actually I was talking about lua libraries which I saw you can use in sources. Calling DLL would be neat too, but lua libraries open a lot of doors already.

ewemoa:
Thanks for the follow-up comment.

I intend to continue looking into getting Alien to work, but in the mean time, here is a rearranged Flua:

  http://ewemoa.dcmembers.com/tmp/FLua-2010-07-09.zip

SHA-1: fd0c178adf51726d529c2e4edc5cd9c753b81add

The main difference in this version is that the core lua portion lives in its own dll (luadll.dll) and that FLua.dll and lfs.dll both link to luadll.dll.

Also included are rex_pcre.dll (also linked to luadll.dll) with pcre.dll and a minor amount of related test code in plugin.lua.

ewemoa:
Here's something preliminary for sqlite 3 access:

  http://ewemoa.dcmembers.com/tmp/lsqlite3.zip

SHA-1: 9de918c90409e4c9cfa879decf5c1d91af07868b

Some brief docs are included for lsqlite3 usage, but the original distribution has more detail. 

To install for use with FLua, I think all that is necessary is to place lsqlite3.dll and sqlite3.dll in the FLua plugins folder.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version