On Sunday, 11 September 2022 09:50:13 PDT samuel ammonius wrote:
> I hadn't really thought of a plan for that, but one way it could be done is
> to create a program that reads the C++ headers and generates their C
> counterparts in a separate file,

Please take a look at existing binding generators, like the one used for 
Python.

> and then edit the C++ header to say
> something like:
> 
> #ifndef __cplusplus
> #include "qpushbutton_c.h"
> #else
> class QPushButton {}
> #endif

Why does it need to be added to the C++ header? Why not have a fully separate 
header tree?

> I'm not sure weather it would be best for the program's output to be
> included in the git repositories, or for the program to be just ran by
> cmake while Qt is being compiled. I definitely can't go over all of Qt
> to add the C bindings myself, but I'd be happy to create and maintain
> something like this if it would work.

That's the point of using automation: to make one person be able to maintain 
this all. If you can convince others to help you, great, that means less work 
for each one individually.

But we'll need a proof of concept this actually works.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Cloud Software Architect - Intel DCAI Cloud Engineering



_______________________________________________
Development mailing list
[email protected]
https://lists.qt-project.org/listinfo/development

Reply via email to