How to include new dirs in @INC
tobez at tobez.org
Mon Jul 23 12:33:10 UTC 2007
On Sun, Jul 22, 2007 at 11:08:44PM -0500, Paul Schmehl wrote:
> I'm working on a port upgrade, and I'm copying some perl modules to
> %%SITE_PERL%%/mach/newdir. Unfortunately, the scripts won't run because
> the perl modules aren't included in @INC. How do I update @INC to include
> the new path? (I have USE_PERL= yes in the Makefile.) Is there a script
> I have to run? Is there an ldconfig for perl?
In theory, one might set environment variable PERLLIB or PERL5LIB. This
won't work for scripts that run with euid and ruid that differ.
Alternatively, the scripts using the modules in a non-standard location must
be modified to "use lib qw(/path)", which modifies @INC.
Alternatively, Perl itself needs to be recompiled with new paths.
Alternatively, you need to figure out whether you can place the modules into
a standard location. It looks like you are trying to do that, but clearly
you are doing something wrong. What are the names of the modules and their
We're going for 'working' here. 'clean' is for people with skills...
-- Flemming Jacobsen
More information about the freebsd-ports