On 02/07/02 16:34 +1000, Ken Williams wrote: > Hi, > > Me again. I'm working on a group of modules that create Inline > interfaces to a certain library (libnode.a). Each module seems > to build fine by itself, but then when I load two such modules > in the same file, I get errors like this: > > dyld: /usr/bin/perl multiple definitions of symbol _HASH_FUNC > blib/arch/auto/AI/NodeLib/NodeLib.bundle definition of _HASH_FUNC > blib/arch/auto/AI/NodeLib/DataSet/DataSet.bundle definition of > _HASH_FUNC
This seems to be a problem specific to OS X. For some reason it exposes all global symbols to other libs when loaded. This should not be the default IMO. I'd really like to know how to turn this behaviour off. Any OS X experts here? Ken, could you see if you have the same problem on Linux (or something) just to see if I'm right here. > > So, I conclude that both modules have linked statically against > libnode.a, and when they're loaded into the same memory space > there's a conflict. Right? > > I'm sort of in unfamiliar territory here, so I'm not sure how to > properly handle this. It seems like maybe the right solution is > for each module to load libnode.a dynamically. Right? Is this > what DynaLoader is for, and if so, what's proper DynaLoader > technique in this situation? > > > -Ken
