5

As we know, Apple introduced it's new "rootless" feature in El Capitan that greatly restricts what the root user is capable of doing. Unfortunately this feature breaks CPAN for Perl users. One can install new CPAN modules but you cannot install a new version of CPAN — because that goes into /usr/bin/. I know I can disable SIP but I'd prefer to work with it for a while.

Anyone know a solution to the CPAN problem?

4

You can install a newer version of cpan in /usr/local/bin with the following CPAN configuration:

cpan
cpan> o conf makepl_arg "INSTALLBIN=/usr/local/bin INSTALLSCRIPT=/usr/local/bin"
cpan> o conf commit
cpan> exit
sudo cpan -i CPAN

This solution, and others, is discussed at perlmonks.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .