Re: [Luarocks-developers] advice and assistance lsqlite3 for Windows
Brought to you by:
loderunner
From: Philipp J. <sif...@gm...> - 2016-11-13 21:24:52
|
Am 13.11.2016 um 19:07 schröbte Doug Currie: > I'm looking for help to construct an appropriate rockspec for an updated > lsqlite3. > > lsqlite3-0.9.4-1.rockspec is uploaded to luarocks.org, and works on OS X > and Debian Linux. It fails on Windows. > > Since 0.9.3, I've added a second module to lsqlite3 called > lsqlite3complete, which statically links sqlite3. The original module > lsqlite3 continues to dynamically link sqlite3. On Windows, building > lsqlite3complete fails due to linker issues (libdl cannot be found, and I > suspect libpthreads will also fail on some systems). > > It seems to me there are two options: > > 1. Use a platform override to prevent building the lsqlite3complete module > on Windows; this is backward compatible to 0.9.3. > > 2. Use platform overrides to fix the linker issues on Windows. > > I'm not sure how to do either one. Can someone help? I've attached a modified rockspec that builds on Ubuntu Linux and on Windows (MinGW and MSVC). But it only contains the statically linked module (I don't have sqlite3 installed as a shared library on Windows). You should pick one of the two options anyway, because as-is building of the module (including the statically linked part) will fail if the shared sqlite3 library isn't available, and if it *is* available, the statically linked version is kinda superfluous ... Some other issues I've found: * test.lua doesn't work for Lua 5.1 due to use of `table.unpack`. * After fixing that, the test.db created with Lua 5.1 and 5.2 is 2.6 Mb big, but only 1.9 Mb with Lua 5.3. I haven't investigated further ... * You should pick either the MIT *or* the MIT/X11 license. Currently the rockspec says MIT/X11, but the documentation/wiki shows the MIT (/Expat) license. > > Thanks! > > e > HTH, Philipp |