[PyKDE] Re-useing sip modules

Phil Thompson phil at riverbankcomputing.co.uk
Tue Jul 27 14:18:01 BST 2004


On Wednesday 21 July 2004 3:14 am, Patrick wrote:
> I've created a sip module called pkaudio that does audio streaming. I want
> to be able to re-use it in subsequent sip modules, but whenever I load the
> sub modules (which depend on pkaudio), the pkaudio lib gets loaded into the
> interpretter twice.
> In a way this makes sense, since I link the pkaudio C++ source into the
> pkaudio module and the dependent sub-module. If I don't link it, I get
> undefined symbols.

I assume that you mean that the sub-module depends on the pkaudio library as 
well as the pkaudio module.

> So, how do modules like PyKDE and Qwt keep from loading the qt library
> twice? I think I'm missing a fundamental concept of linking. Would building
> pkaudio as a shared library fix this?

Yes.

Phil




More information about the PyQt mailing list