How to safely uninstall bioperl that was installed via CPAN?

2.4k Views Asked by At

I installed BioPerl via CPAN. Several tests got failed and I force installed it. I now want to install it via ubuntu software centre.

Can anyone describe how to remove BioPerl that was installed via CPAN using method given here.

2

There are 2 best solutions below

0
On BEST ANSWER

If you'd like to clean up what cpan did first, I would start by running this:

perl -mBio::Perl -e 'print $::INC{"Bio/Perl.pm"}."\n"'

That will show you a path that ends in something like:

...lib/perl/5.10.0/Bio/Perl.pm

I'd just rm -rf the entire Bio directory.

BioPerl also installs a bunch of man pages, probably in /usr/share/man/man3 or /usr/local/share/man/man3. So I'd then run

rm -rf /usr{,/local}/share/man/man3/Bio::*.3pm

There are also files that get put in /usr/bin, and accompying man pages. Remove those with:

rm -rf /usr/{,/local}/bin/bp_*.pl
rm -rf /usr/{,/local}/share/man/man1/bp_*.pl.1
0
On

I don't think there was a way to remove modules using cpan (source install). You can try to locate the module and manually remove the files, but usually you can just ignore the existing files and install the binary package with your package manager.