Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Detect which version of perl an XS module is linked against?

by rafl (Friar)
on Jan 02, 2008 at 23:52 UTC ( [id://660084]=note: print w/replies, xml ) Need Help??


in reply to Detect which version of perl an XS module is linked against?

You can load the xs extension using dlopen (or whatever windows has to realize that functionality - glib has g_module_open which allows to specify if symbols should be resolved lazily or not, so there has to be a way to do that on win32) and tell it to resolve all symbols non-lazily. If that fails it's probably due to some removed library.

Also I wonder why those extensions are linked against libperl. I thought those are loaded from perl/libperl. At least on my unix system I couldn't find a single extension linked to libperl.

  • Comment on Re: Detect which version of perl an XS module is linked against?

Replies are listed 'Best First'.
Re^2: Detect which version of perl an XS module is linked against?
by Limbic~Region (Chancellor) on Jan 03, 2008 at 00:00 UTC
    rafl,
    Thanks for the guidance but unfortunately I need a step-by-step tutorial. Other than Inline::C, I don't have a lot of experience embedding C in Perl nor do I have any experience developing native executables on Win32. Well, aside from what I can accomplish with MinGW and Visual Basic 5 (/me ducks).

    Update: Thanks. Given your reply below, I will work with the #parrot team as any solution needs to be accepted as a patch.

    Cheers - L~R

      DynaLoader provides a dl_load_file function, which will probably do what I said above, except you don't need c or anything.

      Also be sure to set the PERL_DL_NONLAZY environment variable to something true to force nonlazy binding.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://660084]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2024-04-24 07:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found