in reply to Real Static Modules

I’m really looking for a way to get an external static library compiled into a Perl module shared library. Is that even possible?

Definitely possible - in fact that's precisely what happens when you build the perl module against a *static* build of the external library. (Therein lies one reason that I prefer to build static, rather than shared, libraries.)

Your problem, as I see it, is that you want to incorporate a *shared* library into the perl module's '.so'. If that can be done, then I don't know how to do it .... it undoes what shared libraries set out to achieve, so I'm a little sceptical.

Cheers,
Rob

Replies are listed 'Best First'.
Re^2: Real Static Modules
by mpeppler (Vicar) on Oct 02, 2007 at 07:18 UTC
    This indeed feasible on many platforms, but on some platforms you can't dynamically load a .so that has been linked to a .a (or equivalent) file (HP-UX comes to mind).

    As an aside - I was surprised that on AIX (at least 5.2) the links are static by default, so my Sybase.so file is in fact independent of the libct.so, etc. files...

    Michael