Do not change current working directory
KES777 opened this issue · 2 comments
KES777 commented
This does not work (Notice relative path for libraries):
PERL5LIB=lib:local/lib/perl5 local/bin/cpm install -w 16 --no-test -L ./local --snapshot ./cpanfile.snapshot --cpanfile ./cpanfile
Can't locate Parse/PMFile.pm in @INC (you may need to install the Parse::PMFile module) (@INC contains: lib local/lib/perl5/5.36.0/x86_64-linux local/lib/perl5/5.36.0 local/lib/perl5/x86_64-linux local/lib/perl5 /root/perl5/perlbrew/perls/perl-5.36.0/lib/site_perl/5.36.0/x86_64-linux /root/perl5/perlbrew/perls/perl-5.36.0/lib/site_perl/5.36.0 /root/perl5/perlbrew/perls/perl-5.36.0/lib/5.36.0/x86_64-linux /root/perl5/perlbrew/perls/perl-5.36.0/lib/5.36.0) at local/lib/perl5/Menlo/CLI/Compat.pm line 2320.
This does:
PERL5LIB=lib:$(pwd)/local/lib/perl5 local/bin/cpm install -w 16 --no-test -L ./local --snapshot ./cpanfile.snapshot --cpanfile ./cpanfile
DONE install Sort-Naturally-1.03
DONE install Data-Printer-1.001000
...
I often face into this issue, when cpm
blame that libraries are not provided, but they actually they are.
skaji commented
perl Makefile.PL
make
make test
make install
must be executed in distribution's directory.
KES777 commented
May you please document then, that it is required to provide absolute path to local/lib/perl5
if cpm was installed into local library.