[Vm-dev] plugin location

David T. Lewis lewis at mail.msen.com
Thu Aug 27 03:22:12 UTC 2009


On Wed, Aug 26, 2009 at 07:16:42PM -0700, Ian Piumarta wrote:
> 
> Does anyone use the plugin mechanism to load libraries that are not  
> plugins on Unix?  Or to override just one or two of the installed  
> ones from a user directory?
> 
> I'm thinking of simplifying the search strategy (which is indeed  
> broken w.r.t. overriding installed plugins as Subbu points out) along  
> with all the junk related to probing for a zillion prefixes and  
> suffixes.  Unlike libtool, CMake manages to build loadable modules  
> with predictable 'lib*.so' names regardless of the platform.  That,  
> combined with a launch script that can add a -plugins option to the  
> VM args, suggests it ought to be possible to find the plugin  
> precisely on the first attempt, without having to search at all.
> 
> The advantage is vastly simpler logic that is completely predictable.
> 
> The disadvantage is that it will not be possible to subvert the  
> plugin mechanism to load system libraries, and it will not be  
> possible to override the installed plugins with a single plugin built  
> in a different directory.  Would either of these be a noticeable loss?

Predictable and easy to understand is more important than convenience,
so it sounds like a net win to me.

I like being able to work on a plugin that I can build and run from
a local build directory (cd ./build; make; ./squeak myimage) and have 
it find the plugin in the ./build directory. I also like to be able
to run my ./build/squeak under gdb for debugging the plugin. It's nice
if that mechanism continues to work but not essential.

Dave



More information about the Vm-dev mailing list