in reply to Non-root Module Install problems

You want to set PERL5LIB as an environmental variable ...

# Assumes you use (ba)sh PERL5LIB=/path/to/your/lib:/path/to/your/lib/i386-freebsd INC="-I/path/to/your/lib -I/path/to/your/lib/i386-freebsd" export PERL5LIB INC perl Makefile.PL LIB=/path/to/your/lib \ INSTALLMAN1DIR=/path/to/your/lib/man/man1 \ INSTALLMAN3DIR=/path/to/your/lib/man/man3 make make test make install

Note the inclusion of lib/$ARCHNAME (well, i386-freesbsd in the above) in addition to lib, as Perl sometimes has the habit of stuffing Platform dependant modules/bits in that directory rather than lib proper.

IIRC, you should be able to work out what $ARCHNAME should be on your platform by running ...

perl -MConfig -le 'print $Config{q(archname)}'

Update: Setting INC, too (example above updated) should help with make test. :)

    --k.

Replies are listed 'Best First'.
Re: Re: Non-root Module Install problems
by fireartist (Chaplain) on Feb 20, 2002 at 12:22 UTC
    Thanks,
    I tried it and it (appears) to have worked.

    When I came to the 'make test' stage, it failed with the error:
    Can't locate Test.pm in @INC (@INC contains: /usr/lib/perl5/i386-linux +/5.00404 /usr/lib/perl5 /usr/lib/perl5/site_perl/i386-linux /usr/lib/ +perl5/site_perl .) at test.pl line 5. BEGIN failed--compilation aborted at test.pl line 5.
    Which I think is just because I had changed the PERL5LIB variable.

    Anyway, I continued with 'make install', which succeeded.
    I then wrote a little cgi that created a new HTML::Template object from a file, and filled it with a single variable.
    So this (very basic) test suggests that it is fine.

    Thank you.
    fireartist