Jim Bublitz jbublitz at nwinternet.com
Fri Aug 8 17:15:01 BST 2003

On Friday August 8 2003 00:54, Andreas Pour wrote:
> Jim Bublitz wrote:
> > On Thursday August 7 2003 22:53, Andreas Pour wrote:
> > I assume you already know about the need to 'export
> > KDE_MALLOC=0", as you'd probably be getting segfaults
> > otherwise.
> Well, crap, I did it with qt.py but not the others.  I have to
> do it for each .py module and then recompile it to the .pyc? 
> I would think the KDE modules load the Qt modules and get the
> environment variable set that way?

For SuSE, you just either need to export it when you open a new 
konsole or else just stick it in the user's .bashrc (.profile 
doesn't seem to affect KDE konsoles) You bascially only need to 
do it once for a konsole session if doing it manually. It 
affects both PyQt and PyKDE.

> It looks like that; since kaccelbase.h is not disstributed
> with KDE (not a public API) it's hard to tell when and how it
> changed.  Suffice it to say KDE 3.0.3 does not have the
> virtual function either; not sure when it was introduced.  See
> http://webcvs.kde.org/cgi-bin/cvsweb.cgi/kdelibs/kdecore/kacce
>lbase.h (looks like it was taken out for 3.1.3 but not sure
> when it was introduced - the revision is at
> http://webcvs.kde.org/cgi-bin/cvsweb.cgi/kdelibs/kdecore/kacce
>lbase.h.diff?r1=1.19&r2=1.20&f=h but maybe there was more
> back-and-forth and I don't know what KDE version that
> corresponds to either ;-) ).

kaccelbase.h is in the extra/ subdirectory and is taken from the 
kdelibs source tarball for the appropriate version. There are 
half a dozen or so .h files that are necessary but not usually 
in kde3/include (and a few h files that need some mods to work 
with sip or my code generator). Those h files are all included 
with PyKDE under extra/ and build.py points the make files to 
the correct versions (eg extra/kde303/kaccelbase.h). 

virtual_hook (if I remember correctly) was just kind of 
arbitrarily added all over the  place one day by someone back in 
the KDE 2 or early KDE 3 days. There's some discussion on one of 
the KDE lists, and some of it is fairly unfavorable. It was 
apparently added for some debugging reason that didn't seem real 
necessary to me, and it pops up from time to time and causes me 

> > Running grep on the sip directory, however, I find the
> > following files have virtual_hook methods that aren't
> > commented out:

> > kaction.sip (*2* instances), kar.sip, knuminput.sip,
> > ktextedit.sip and kzip.sip. In each case, all you need to do
> > is comment out the offending method:

> >     virtual void         virtual_hook (int, void*);

> > should be:

> >    //    virtual void         virtual_hook (int, void*);

> None of the others is a problem and with 3.1.1 it is not a
> problem as it is :-).

It doesn't cause any problems here on any version, but it should 
break everything - kind of scary that it doesn't. It shouldn't 
be possible to load a lib (PyKDE module) with unresolved 


More information about the PyQt mailing list