terrencebrown has asked for the wisdom of the Perl Monks concerning the following question:

Although I am novice, I love Perl. But, how do you get rid of it?

Horror falls upon some Perlers at the thought uninstalling their beloved. While it may seem a strange thought to some, most programs should come with an "UNINSTALL" button. Perl eerily does not.

A recent tutorial on Perl.com regarding threads and elevators required the installation of Perl 5.8.0 using threads turned on. After reading the intriguing article I configured and installed Perl on Readhat Linux 8.0 according to the directions. However, a quick "perl -v" determined that the threaded version supplanted the old one even though the new version was installed in a completely different directory.

I experienced sheer joy at the wonder of threads but anxiety at the thought of having to leave the current threaded installation in place. This threaded version of Perl is much more CPU intensive and would therefore not be acceptable for use on daily critical tasks.

After scouring the web and finding no good discussion on the matter, I contacted the author of the piece. He had never tried to uninstall Perl but suggested the monks as the best source of wisdom.

Having said all that, has anyone uninstalled Perl and what was your experience?

Thank you so much,
Terrence Brown

update (broquaint): title change (was Uninstalling Perl)

Replies are listed 'Best First'.
(tye)Re: Uninstalling Perl
by tye (Sage) on Nov 23, 2002 at 05:30 UTC

    Something very similar to:

    rm -rf /usr/local/lib/perl rm -f /usr/bin/perl
    will likely leave no trace of Perl other than man pages that you might have installed someplace like /usr/local/man/man1 and /usr/local/man/man3 (but I never installed those and with perldoc, installing them is even less of a good idea than it used to be).

    See also the output of the command perl -V and/or your Config settings.

            - tye
Re: Uninstalling Perl
by terrencebrown (Acolyte) on Nov 23, 2002 at 06:12 UTC

    Thank you for the wisdom. Just to be clear, though, I wanted to only uninstall the second installation of Perl at ~/myperl and not the one at /usr/bin/perl. I did want to revert back to the previous installation. I don't think I was clear about that.

    And, would merely renaming the threaded Perl send my system looking for something that didn't exist?

    I guess a better subject line would have been "Reverting Perl".

Re: Uninstalling Perl
by gjb (Vicar) on Nov 23, 2002 at 21:11 UTC

    If you simply make sure that ~/myperl is not in your path (or root's path for that matter), you'll never be bothered by it again unless you want to.

    You can even run specific scripts with the 5.8.x release either by typing ~/myperl/perl your-script.pl or putting #!~/myperl/perl as first line in the script.

    Incidently, please don't take this as an offence, but this is not a Perl problem, but rather UNIX related, so I think it would help if you read a bit more on that subject.

    Hope this helps, -gjb-

Re: Uninstalling Perl
by BUU (Prior) on Nov 23, 2002 at 04:54 UTC
    Uh, change your path? Rename the threaded perl.exe? Move either/or?
Re: Uninstalling Perl
by PodMaster (Abbot) on Nov 24, 2002 at 10:52 UTC
    When I'm uninstalling perl modules, I use ExtUtils::Installed, when i'm uninstalling perl, I use Config.

    Whenever i'm installing a new version of perl, I always install it all under a path of my choosing (installprefix), that way I can simply say rm -rf /a/place/where/i/keep/perl.

    Seeing the "pickle" you're in, I suggest you examine Config, ie

    perl -V:.+|grep install # or for the grepless perl -V:.+|perl -ne" print if /install/ "
    I get back
    installarchlib='C:\Perl\lib'
    installprivlib='C:\Perl\lib'
    installbin='C:\Perl\bin'
    installhtmldir='C:\Perl\html'
    installhtmlhelpdir='C:\Perl\htmlhelp'
    installman1dir=''
    installman3dir=''
    installprefix='C:\Perl'
    installprefixexp='C:\Perl'
    installscript='C:\Perl\bin'
    installsitearch='C:\Perl\site\lib'
    installsitebin='C:\Perl\bin'
    installsitelib='C:\Perl\site\lib'
    installstyle='lib'
    installusrbinperl='undef'
    installvendorarch=''
    installvendorbin=''
    installvendorlib=''
    
    It's a safe bet for me to do a
    perl -MConfig -MFile::Path -e" rmtree($Config{installprefix}) "
    and get rid of whatever perl i'm currently using.

    update: Sometimes I even suprise myself ;)

    perl -V:install.+


    MJD says you can't just make shit up and expect the computer to know what you mean, retardo!
    ** The Third rule of perl club is a statement of fact: pod is sexy.

Re: Reverting Back to other Perl Install
by terrencebrown (Acolyte) on Dec 13, 2002 at 15:21 UTC
    Thank you all for your help. I have great Perl install running now for hacking and slashing. Be good.