On Mon, 7 Apr 2008, Sisyphus wrote:

>>    sv_setiv(perl_get_sv("PDL::SHARE",TRUE), PTR2IV(&PDL));
>>
>> But I'm not sure what to do to get around this.
>
> Well spotted. I've managed to create a simple demo script that's in no way
> related to PDL:
>
> Is $PDL::SHARE ever actually used ?
>

Yes. It contains a pointer to all the PDL C API functions. You need to get 
the PDL::SHARE variable in XS code to access PDL functions in external C 
modules. You can't do it by relying on the linker because when a program 
loads two shared libraries, generally those shared libraries can't see 
each other.

-- 
Tim Jenness
JAC software
http://www.jach.hawaii.edu/~timj


_______________________________________________
Perldl mailing list
[email protected]
http://mailman.jach.hawaii.edu/mailman/listinfo/perldl

Reply via email to