Sorry Jens,

I read too quickly.   The app is for the physical and engineering sciences, and 
will perform a least squares fit of experimental data to different physical 
models.    The models for the experimental data will be in the plugins, and the 
user will likely only need to the load a few of the plugin models.   In the 
host app (actually in one of it's static libraries dedicated to handling SI 
Units) is a static variable pointing to a singleton library (CFMutableSet) with 
a growing set of SI units available in the main app (and plugins).   The units 
are flyweights, so I don't want multiple copies floating around the program.

So, I can't really define the static variable pointing to my library in the 
plugin.    It needs to be defined in the library that handles all the SI units.

Is it still possible to tell the linker to export the static variable pointing 
to my SI Units library in such a situation? 

Thanks again,

Philip

On Jan 1, 2012, at 9:49 PM, Jens Alfke wrote:

> 
> On Jan 1, 2012, at 2:21 PM, Grandinetti Philip wrote:
> 
>> Your suggestions make sense, although...
>> option (a) doesn't work for me, since the static variables are being used 
>> before the plugin is loaded.   
> 
> They're not options, they're steps. You need to do all of them.
> 
> If you can't put the variable in the plugin, I _think_ you can put it in the 
> app, then export it from the app and link the plugin against the app. Apps 
> don't normally export symbols, but I think you can set this up.
> 
> Maybe you could explain what the plugin does and why it and the app need to 
> share a variable?
> 
> —Jens

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to