in reply to Problems with CPAN: installing Tk

Sure... so to speak, lots and lots of people do.   This is really a specific case of a more-general concern.   Start by surfing the many posts on “installing Perl as a non-root user.”

You see, here’s the issue...   you are (quite sensibly!) “just an ordinary user.”   (If you do happen to own a Superduperman Suit, you’re not wearing it now.   Wise Move.)   And CPAN, having not yet been instructed to do any differently (yet...), is attempting to install things into the “system-wide” locations, which you as an ordinary mortal have no read/write access to.

But that certainly isn’t your only option, and, believe me, you really do want to leave all those system-wide directories well enough alone!   :-O   (Many operating systems and “distros” make use of Perl as the engine to run lots of their system-maintenance stuff.   You really don’t want to run the risk of disturbing any of that.)   Here’s the way to do it.   All of “your” CPAN materials will be installed into a set of directories that you can write to, and you’ll arrange for that directory to be considered first.   So you can have as many customized CPAN libraries as you care to.

You set up your own separate you-writeable directory, and then you point CPAN to that location as the place to install things.   Then, add it to your PERL5LIB path.   All of which is neatly explained ... because this is exactly what folks have to do when they, say, install Perl-based web software on a shared-hosting system.   (Ditto PHP and Ruby and Python and every other language...)