Static link option?

Hi all. In my application I typically do a

  from wxPython.wx import *;

to get easy access to everything. The only downside is that,
on my system, this takes about 2 seconds. In contrast, all
my other python importing takes negligable time.

I'm presuming that most of this time is taken by loading the
DLL. Is there a way of linking the wxPython DLL statically
to bypass the DLL loading?

···

-------------------------------------------------------------------------------------
Jeff Kotula Systems Architecture Manager
Vital Images jkotula@vitalimages.com

Renunciation is not giving up the things of this world,
but accepting that they go away.
    -- Suzuki Roshi

Jeff Kotula wrote:

Hi all. In my application I typically do a

  from wxPython.wx import *;

to get easy access to everything. The only downside is that,
on my system, this takes about 2 seconds. In contrast, all
my other python importing takes negligable time.

I'm presuming that most of this time is taken by loading the
DLL.

Dlls. Plural. All the extension modules are DLLs too.

Is there a way of linking the wxPython DLL statically
to bypass the DLL loading?

Theoretically, yes. It's been about 3 years since I've done this (pre-distutils.) Not only do you need to link with the static wx lib, but you need to link all the wxPython extension modules into a single extension module as there can only be one instance of wxWindows in a single process.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!