How can I install a CPAN module into a local directory?

前端 未结 5 1684
庸人自扰
庸人自扰 2020-11-22 16:17

I\'m using a hosted Linux machine so I don\'t have permissions to write into the /usr/lib directory.

When I try to install a CPAN module by doing the us

5条回答
  •  情话喂你
    2020-11-22 16:51

    local::lib will help you. It will convince "make install" (and "Build install") to install to a directory you can write to, and it will tell perl how to get at those modules.

    In general, if you want to use a module that is in a blib/ directory, you want to say perl -Mblib ... where ... is how you would normally invoke your script.

提交回复
热议问题