On Sun, Nov 02, 2003 at 11:56:50AM -0500, H.Wade Minter wrote:
> I'd like to update my ports-installed version of Perl from 5.8.0 to 
> 5.8.1.  On my test system, I did a "portupgrade -rR perl", but it 
> didn't update any of my installed p5- modules, which caused breakage 
> until I reinstalled all of them by hand.
> Is there a better way to update Perl?  Would a "portupgrade -rRf" have 
> helped?

Yes -- I had to do this on two machines (well, one machine and a jail
but the difference is immaterial).  After running into the problems
you describe, and realising that most of the perl modules I had
installed didn't show up as dependencies of perl, and after doing the
first one I reckoned the best move was to use brute force.

Generate a list of all of the ports that install files under
/usr/local/lib/perl5/5.8.0 and /usr/local/lib/perl5/site_perl/5.8.0:

    find /usr/local/lib/perl5/5.8.0 /usr/local/lib/perl5/site_perl/5.8.0 \
        -type f -print | xargs -L 1 pkg_which | sort -u > /tmp/perl-files

It's quite likely that you'll see several several files claimed by
both perl and a perl module port.  In this case, you don't need to
install the separate port as perl-5.8.1 comes with the latest versions
of everything.

The procedure then is to pkg_delete all of the ports that install
anything under those two directories, except for perl itself.

Then portupgrade -f perl and re-run use.perl port

Then re-install all of the perl-based ports.

After that, you'll need to run pkgdb -Fvu to fix up any dependencies.
Some ports expect to have various perl modules installed as
dependencies, which are now available as part of the standard set of
perl modules, so edit the dependencies appropriately.



Dr Matthew J Seaman MA, D.Phil.                       26 The Paddocks
                                                      Savill Way
PGP: http://www.infracaninophile.co.uk/pgpkey         Marlow
Tel: +44 1628 476614                                  Bucks., SL7 1TH UK

Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to