develooper Front page | perl.perl5.porters | Postings from April 2001

Relocatable perl

Thread Next
Alan Burlison
April 30, 2001 08:42
Relocatable perl
Message ID:
Solaris will have two new features that may make it possible to finally
achieve the Holy Grail of a truly relocatable perl.  The first of these is
the ability to refer to a library with a path that is relative to the
executable (removing the need for LD_LIBRARY_PATH hackery) and the second is
the ability to find out the path of the executable from inside the
executable (removing the need for PERL5LIB hackery).

I've been trying to figure out what sort of stuff would need changing to
make this work.  At first I just thought that the equivalent of setting
PERL5LIB would do, but a bit of searching around uncovered the following
#defines that refer to the perl install location, and that are used in the

I suspect that to make this work I'd have to make all of those #defines into
dynamic strings, and tweak them at startup.  Does this seem correct?  Where
would I put them?  Globals?  This would only work if the above variables all
had a common directory prefix - if someone decided for some reason to tell
Configure they wanted SITELIB_EXP on a completely different filesystem there
would be no common directory prefix to twiddle.

Is this really worth the effort?

Alan Burlison

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About