in reply to Re: perl module not getting listed for non root user
in thread perl module not getting listed for non root user

Thanx for the reply.
The link suggested by you mentions about using the perl modules installed in my home directory.
My issue is that I have the perl modules installed by the root under /usr/opt. I want to use these perl modules only.
  • Comment on Re^2: perl module not getting listed for non root user

Replies are listed 'Best First'.
Re^3: perl module not getting listed for non root user
by eosbuddy (Scribe) on Aug 12, 2008 at 06:10 UTC
    One way is to have all your programs access the modules via pragmas of the following type:
    #!/usr/bin/perl use lib "/usr/opt/<path-to-perlmodule-folder>";
    The other way is to specify the path in each user's .bashrc or .login which is called when you login like this (you can also make an entry in /etc/bash.bashrc or /etc/login.defs or equivalent files so that new users you add automatically get it into their login rc files).
    export PERL5LIB=/usr/opt/<path-to-perl5-module-folder>