I have been in contact with Julian Smart of wxWidgets and he has written
a patch to wxWidgets so that XRC can avoid loading all the mime types at
startup.

The patch is now in 2.8 and 2.9 SVN

Before loading an XRC file, the user has to add

Wx::SystemOptions::SetOption("filesys.no-mimetypesmanager", 1);

This will suppress the mime load.

Peter

On Mon, 2008-06-23 at 21:02 +0300, Peter Gordon wrote:
> Eric,
> 
> I have an application that I am running on Fedora 9 with XRC
> that doesn't seem to have any undue start up problems.
> 
> I know that for wxWidgets 2.6 I had the problem. Do you happen to have
> an example of a perl program with XRC that takes a long time to load. If
> so, I will see if I can help get it the Mime problem fixed.
> 
> Peter
> 
> 
> On Sun, 2008-06-22 at 10:56 -0700, Eric Wilhelm wrote:
> > # from Peter Gordon
> > # on Sunday 22 June 2008 10:29:
> > 
> > >(and XRC isn't really an option unless the
> > >
> > >> mime-type-initialization penalty in loading XRC goes away.)
> > >
> > >There is a way around the mime-type limitation.
> > >Compile wxWidgets without mime and then XRC works very nicely.
> > 
> > That works for *my computer* or if I ship a build with the program, but 
> > what if the user (or even the program) needs mime?  Even if they don't 
> > need it, explaining to your users that they should recompile is quite a 
> > pain.
> > 
> > Until the penalty (around 7 seconds - depending on the disk cache) of 
> > loading every mime database on the system can be eliminated by 
> > something other than a compile-time feature-removal option, I can't see 
> > XRC as a viable option.
> > 
> > --Eric
> 

Reply via email to