<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Side-loading my own Qt.dll on default PiSide2 installed with pip]]></title><description><![CDATA[<p dir="auto">Hi all.</p>
<p dir="auto">I'm working on a Python + Qt (PySide2) project.</p>
<p dir="auto">Since I want to fix a bug in Qt (that I've already submitted), I want to build my own version of the Qt libraries (Core, GUI and Widgets) and give a try at bug fixing.</p>
<p dir="auto">Also having access to the Qt source code means that, if needed, I can tackle performance issues and bugs C++ side.</p>
<p dir="auto">Here is my workflow:</p>
<ul>
<li>I've installed Python 3.10.6 on my Windows machine;</li>
<li>I've created a virtual env and "pip installed" PySide2 version 5.15.2.1;</li>
<li>I've used git to download Qt 5-5.15.2 and I've built my own version of Qt (the idea is to manipulate Qt source code later on);</li>
<li>I've copied my Qt5Core.dll, Qt5Gui.dll and Qt5Widgets.dll inside &lt;venv folder&gt;\Lib\site-packages\PySide2 overwriting the *.dlls already there;</li>
</ul>
<p dir="auto">At this point I can run my PySide2 app, but it crashes randomly after 10 minutes or so, segfaulting.</p>
<p dir="auto">Before going deeper into the issue, my question is: is my workflow ok? Is overwriting the *.dlls sufficient? Do I need to build Shiboken too? Do I need to build PySide2 too?</p>
<p dir="auto">If I run "dumpbin /headers Qt5Core.dll" for my version of the library, I get:</p>
<pre><code>Microsoft (R) COFF/PE Dumper Version 14.29.30146.0
Copyright (C) Microsoft Corporation.  All rights reserved.


Dump of file Qt5Core.dll

PE signature found

File Type: DLL

FILE HEADER VALUES
             14C machine (x86)
               6 number of sections
        630B79FC time date stamp Sun Aug 28 16:21:48 2022
               0 file pointer to symbol table
               0 number of symbols
              E0 size of optional header
            2102 characteristics
                   Executable
                   32 bit word machine
                   DLL

OPTIONAL HEADER VALUES
             10B magic # (PE32)
           14.29 linker version
&lt;many other (probably useless) rows&gt;
</code></pre>
<p dir="auto">If I run "dumpbin /headers Qt5Core.dll" for the official "pip install" library, I get:</p>
<pre><code>Microsoft (R) COFF/PE Dumper Version 14.29.30146.0
Copyright (C) Microsoft Corporation.  All rights reserved.


Dump of file Qt5Core.dll

PE signature found

File Type: DLL

FILE HEADER VALUES
             14C machine (x86)
               6 number of sections
        61D69156 time date stamp Thu Jan  6 07:51:02 2022
               0 file pointer to symbol table
               0 number of symbols
              E0 size of optional header
            2102 characteristics
                   Executable
                   32 bit word machine
                   DLL

OPTIONAL HEADER VALUES
             10B magic # (PE32)
           14.26 linker version
&lt;many other (probably useless) rows&gt;
</code></pre>
<p dir="auto">I have the feeling that the different "linker version" (different compiler minor version) is causing a binary incompatibility.</p>
]]></description><link>https://forum.qt.io/topic/139197/side-loading-my-own-qt-dll-on-default-piside2-installed-with-pip</link><generator>RSS for Node</generator><lastBuildDate>Thu, 05 Nov 2026 02:38:26 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/139197.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 09 Sep 2022 15:20:10 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Side-loading my own Qt.dll on default PiSide2 installed with pip on Tue, 27 Sep 2022 21:34:45 GMT]]></title><description><![CDATA[<p dir="auto">Compiling PySide2 from scratch, pointing the build process to the custom Qt solved the issue.</p>
]]></description><link>https://forum.qt.io/post/730420</link><guid isPermaLink="true">https://forum.qt.io/post/730420</guid><dc:creator><![CDATA[OniNiubbo]]></dc:creator><pubDate>Tue, 27 Sep 2022 21:34:45 GMT</pubDate></item><item><title><![CDATA[Reply to Side-loading my own Qt.dll on default PiSide2 installed with pip on Fri, 09 Sep 2022 18:15:09 GMT]]></title><description><![CDATA[<p dir="auto">Hi and welcome to devnet,</p>
<p dir="auto">I would go with building PySide2 as well with your version of Qt. That way you ensure that you have everything using the same toolchain.</p>
]]></description><link>https://forum.qt.io/post/728091</link><guid isPermaLink="true">https://forum.qt.io/post/728091</guid><dc:creator><![CDATA[SGaist]]></dc:creator><pubDate>Fri, 09 Sep 2022 18:15:09 GMT</pubDate></item></channel></rss>