[PyKDE] PyQt 3.1, Win2000, and MSVC runtime library

Paul Felix pef at fluent.com
Thu Apr 11 16:27:31 BST 2002


Hi,

I want to pass on a fix I made to the Windows build of PyQt/Sip 3.1 using
MS VC++.

My build configuration is as follows:

  NT 4.0 SP 5
  VC++ 6.0 SP 5
  PyQt/Sip 3.1
  Qt 3.0.3
  Python 2.2.0

After building PyQt, I was able to run the PyQt examples on my NT 4.0 box, but
when I ran the examples on a Win2000 box, they crashed at various times (most
often when exiting the app).  Here is the Win2000 configuration I tested:

  Windows 2000 Professional
  5.0.2195 SP 2

While investigating, I noticed that the build was mixing static (MT) and DLL
(MD) versions of the C runtime library:

  Package     C runtime option
  -------     ----------------
  Python         -MD
  Qt             -MD
  PyQt/Sip       -MT

This is a no-no according to our friends at Microsoft:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore98/HTML/_core_.2f.md.2c_2f.ml.2c_2f.mt.2c_2f.ld.asp

I went back to the PyQt/Sip build and changed the Makefile.win32-msvc files,
replacing -MT with -MD.  Now the examples run fine for me on both NT 4.0 and
Win2000.

This is a head scratcher, because I know some of you are running on Win2000
without problems -- maybe you made this fix too.

Paul
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pef.vcf
Type: text/x-vcard
Size: 241 bytes
Desc: Card for Paul Felix
Url : http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20020411/d9c1198f/pef.vcf


More information about the PyQt mailing list