Compiling a mixed D and C++ project?
Kyle De'Vir
kyle.devir at mykolab.com
Mon Sep 2 16:37:57 UTC 2019
On Monday, 2 September 2019 at 15:58:12 UTC, Gregor Mückl wrote:
>
> Do you compile in the moc-generated code for TestApplication?
>
> "undefined reference to vtable" is a stupid gcc quirk. It only
> emits the vtable for a C++ class under certain circumstances. I
> think it puts it in the object file for the source file that
> has the implementation of the first virtual method in the class
> definition. If TestApplication is derived from QObject and
> uses the Q_OBJECT macro, then this virtual method is one that
> is created by moc for signal/slot handling.
I was fiddling around, and compiling in the moc-generated code
fixed the vtable errors.
It was still complaining about `SetAppAtrributes`. Removing the
function allowed it compile, but then I just get a segfault when
trying to run it, which I have no way of understanding how to
begin debugging. :|
I might just fall back to making the Qt the frontend, with the
Dlang code the backend. Sounds less messy. :(
More information about the Digitalmars-d
mailing list