PtokaX forum

Development Section => Extensions for PtokaX Lua => Topic started by: PPK on 09 September, 2011, 09:09:23

Title: LuaSQLite3 0.8
Post by: PPK on 09 September, 2011, 09:09:23
LuaSQLite3 with SQLite 3.7.7.1 for PtokaX 0.4.1.2 build 240 and higher (Lua 5.1.4 only).

Homepage: http://lua.sqlite.org/

Binary: http://www.PtokaX.org/files/Libs-240/LuaSQLite3-0.8-sqlite-3.7.7.1.7z
Binary x64: http://www.PtokaX.org/files/Libs-240/LuaSQLite3-0.8-sqlite-3.7.7.1-x64.7z

Source: http://www.PtokaX.org/files/Libs-240/LuaSQLite3-0.8-sqlite-3.7.7.1-src.7z

Initializing:

require "lsqlite3"


This will register global sqlite3, more is in docs 8)
Title: Re: LuaSQLite3 0.8
Post by: whitestatic on 01 February, 2012, 05:03:53
Is there any chance somebody could build a copy of this with FTS3 & FTS4 support? (http://www.sqlite.org/fts3.html#section_2)
Title: Re: LuaSQLite3 0.8
Post by: whitestatic on 01 February, 2012, 07:31:34
Just gave it a go myself and failed miserably. Used the sources from http://forum.ptokax.org/index.php?topic=8849.0 to generate the PXLua.lib file to compile LuaSQLite against. Everything compiled OK but I could not require() it from a LUA script (the DLL in the first post works fine for this script). It complained about PXLua.dll missing an entry point for create_metatable or some such function. So I replaced the PXLua.dll in the PtokaX folder with the one I had compiled from the sources, but then PtokaX failed to start.

If somebody who actually knew what they were doing could compile this that would be awesome.

I'm running PtokaX version 0.4.2.0 (build 241) if that makes a difference.
Title: Re: LuaSQLite3 0.8
Post by: PPK on 01 February, 2012, 10:19:58
Updated LuaSQLite3 with SQLite 3.7.10 and enabled FTS3 & FTS4 for PtokaX 0.4.1.2 build 240 and higher (Lua 5.1.4 only).

Homepage: http://lua.sqlite.org/

Binary: http://www.PtokaX.org/files/Libs-240/LuaSQLite3-0.8-sqlite-3.7.10.7z
Binary x64: http://www.PtokaX.org/files/Libs-240/LuaSQLite3-0.8-sqlite-3.7.10-x64.7z

Source: http://www.PtokaX.org/files/Libs-240/LuaSQLite3-0.8-sqlite-3.7.10-src.7z
Title: Re: LuaSQLite3 0.8
Post by: PPK on 01 February, 2012, 10:24:11
Quote from: whitestatic on 01 February, 2012, 07:31:34
Used the sources from http://forum.ptokax.org/index.php?topic=8849.0 to generate the PXLua.lib file to compile LuaSQLite against.
PXLua.lib in that archive, you don't need to generate it ;)
Title: Re: LuaSQLite3 0.8
Post by: whitestatic on 02 February, 2012, 01:14:00
Thats awesome, thanks. I've just had a play with it and it works beautifully :).

Quote from: PPK on 01 February, 2012, 10:24:11
PXLua.lib in that archive, you don't need to generate it ;)

I tried linking with that, but it failed to build - complained about a number of unknown Lua functions. Hence why I tried building my own. Not sure what was going on there ????

Thanks for all your work.
Title: Re: LuaSQLite3 0.8
Post by: PPK on 02 February, 2012, 14:25:29
Maybe you used different compiler or some different compiler configuration :-X
Title: Re: LuaSQLite3 0.8
Post by: PPK on 01 April, 2012, 10:29:24
New version for PtokaX 0.4.2.0 build 376 and higher.

Binary: http://www.PtokaX.org/files/Libs-376/LuaSQLite3-0.8-sqlite-3.7.11.7z
Binary x64: http://www.PtokaX.org/files/Libs-376/LuaSQLite3-0.8-sqlite-3.7.11-x64.7z
Source: http://www.PtokaX.org/files/Libs-376/LuaSQLite3-0.8-sqlite-3.7.11-src.tar.gz

This lib is compatible with PXLua 5.1.5, 5.2.0 and 5.2.1 ;)

Update 8/May/2012: