lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On 14/04/16 16:45, Marc Balmer wrote:
>> Am 14.04.2016 um 16:36 schrieb Scott Morgan <blumf@blueyonder.co.uk>:
>>
>> What's the state of Qt 5 bindings for Lua?
...
>> QtLua: I can get to build, but it doesn't pick up on any of the widget
>> classes. May be a bad/missing compiler directive as it looks like an
>> issue in qtluaqmetaobjecttable.cc not picking up on static member addresses.
> 
> I recently fixed some bugs ib libqtlua, to make it work with Qt5.
> 
> I think that fixes made it to repository, but I will double check.

I think part of the problem is I'm using the cmake project files, which
might not be in sync with the autotools ones.


For ref. the problem I'm seeing is, in qtluaqmetaobjecttable.cc there's:

const meta_object_table_s meta_object_table[] = {
... etc.
  { &QCheckBox::staticMetaObject, &create_qobject<QCheckBox> },
... etc.
}


But the &QCheckBox::staticMetaObject value (and all the others, except
for the QtLua internal ones) is being set as 0 and thus ignored. In the
actual qtlua executable that value returns a valid address, so I think
it's something to do with the linking of the libqtlua.dll to the Qt dlls.

I think I saw something about dll/so files needing to be linked
differently to Qt than exes, but haven't dug into that yet.

(this is all in Qt Creator's Windows build with their mingw tool chain,
if that makes a difference)

Scott