Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: how do you determine which module needs to be updated while using perlbrew?

by kcott (Archbishop)
on Aug 01, 2025 at 16:45 UTC ( [id://11165914]=note: print w/replies, xml ) Need Help??


in reply to how do you determine which module needs to be updated while using perlbrew?

I've just installed v5.42.0 via Perlbrew using the commands shown under Quickstart:

To install the latest stable release ...

perlbrew install perl-5.42.0 perlbrew switch perl-5.42.0

I'm guessing your "perlbrew install stable" would achieve the same result.

I've also installed a number of modules, via the cpan utility, including namespace::clean. I repeated your commands:

ken@titan ~/tmp $ perl -E 'use namespace::clean' ken@titan ~/tmp $ perl -v This is perl 5, version 42, subversion 0 (v5.42.0) built for cygwin-th +read-multi Copyright 1987-2025, Larry Wall ...

So, there's nothing inherently wrong with the perl-5.42.0 from Perlbrew. I acknowledge that you're using Linux and I'm using Cygwin — for test commands as simple as the ones above, I don't believe this would make any difference.

It is a fairly common mistake to copy modules from one Perl version to another; for instance, I might have tried:

ken@titan ~/perl5/perlbrew/perls $ cp perl-5.40.0/lib/site_perl/5.40.0/namespace/clean.pm perl-5.42.0/l +ib/site_perl/5.42.0/namespace/clean.pm

Had I done so, I could have expected an error such as you're getting. I don't know if this is what you've done but your results are suggesting something like this has occurred. Here's some basic information:

  • Modules with a compilation requirement cannot be copied successfully to a new Perl version — you must recompile them (installing from CPAN does this for you).
  • Modules which appear to be pure Perl may have dependencies with a compilation requirement — see previous point.
  • Very simple pure Perl modules with no dependencies can probably be copied safely; however, it's likely to be easier to reinstall from CPAN than going to the trouble of checking source code.

I note ibm1620 suggested clone-modules. I've never used that but it may suit your needs. See perlbrew: COMMAND: CLONE-MODULES for documentation.

Finally, please consider registering — see Create A New User. You won't be asked for your life story like some forums; we'll be able to tell you apart from other Anonymous Monks; and, you'll find quite a few benefits such as editing your posts, customising the GUI, and others.

— Ken

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11165914]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (2)
As of 2026-03-09 00:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.