[External] Re: building code already generated by sip-build
Edward A. Pier
epier at oceanit.com
Fri Nov 17 13:29:11 GMT 2023
Just running make was my first thought, but I don't see a Makefile (or equivalent for any other build system) anywhere. I only see the generated .cpp and .h files and the .o files in the build directory. Poking around the sip Python code, it seems like the compilation and linking are orchestrated there. In theory I could roll my own Makefile, but that is unappealing, giving the number of compiler flags.
Any other ideas? A different approach would be if there was a way to inject code into the sipAPIxxx.h file.
-ED
________________________________
From: Phil Thompson <phil at riverbankcomputing.com>
Sent: Thursday, November 16, 2023 11:53 PM
To: Edward A. Pier <epier at oceanit.com>
Cc: pyqt at riverbankcomputing.com <pyqt at riverbankcomputing.com>
Subject: [External] Re: building code already generated by sip-build
[You don't often get email from phil at riverbankcomputing.com. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
On 16/11/2023 14:12, Edward A. Pier wrote:
> I am using sip to wrap some Qt-related C++ code in Python. I am
> running sip-build 6.7.12 under MSYS2 on Windows.
>
> The project compilation fails with a long spew of errors coming from
> the qmetatype.h header file which is included by sipAPIxxx.h (I
> substituted xxx for the project name).
>
> The includes at the top of that file look like this:
>
> #include "sip.h"
>
> #include <QMetaType>
> #include <QThread>
>
> I find that if I swap the order of the QMetaType and QThread includes,
> it compiles.
>
> While it would be nice to understand and fix the ultimate cause of
> this problem, I would settle for a workaround where I generate the
> code, then modify the generated code, and then compile. I see there is
> a --no-compile option on sip-build that would handle the first thing,
> but I don't see a way to just compile already generated code with all
> the necessary compiler flags.
>
> Thanx for your help, and let me know if you need any more info.
Just run make?
Phil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20231117/371d9379/attachment.htm>
More information about the PyQt
mailing list