in reply to A simple library question

Er, when you install a Perl module in the way that is appropriate for your platform (CPAN, PPM, RPMs or whatever) the files will be placed in the correct location.

If you have installed (or even simply copied) the modules files into a non-standard location then you have to tell Perl where that is using the lib pragma:

use lib qw(/my/module/directory ./lib);
You can read about this in the lib manpage

/J\

Replies are listed 'Best First'.
Re^2: A simple library question
by rjbs (Pilgrim) on Jul 14, 2004 at 11:58 UTC
    Yeah, I think this monk needs to focus his attention on why something like CGI::Session isn't in an acceptable place to begin with.

    cranberry13: how did you install it? Did you use CPAN.pm, or did you use "make; make test; make install" or did you do something else?
    rjbs
      Sounds like CGI is either broken, not installed, or..

      if somehow your system has 2 versions of Perl installed, and you did install CGI, you may be invoking the other Perl version inadvertently...

      Adding a path to @INC can be done as described by the other monks but may not be the root of your problem