develooper Front page | perl.perl5.porters | Postings from December 2010

Where should dual-life modules from CPAN be installed?

Thread Next
David Golden
December 27, 2010 03:51
Where should dual-life modules from CPAN be installed?
Message ID:
Historically, dual-life modules added to core had logic like this in
their Makefile.PL or Build.PL:

  installdirs   => ($] >= 5.009004 ? 'core' : 'site'), # Build.PL style

(That is from Module::Build, which was added to core in 5.10.)

Now that 5.12 re-orders @INC to put site libraries before core
libraries, should all dual life modules be installed to 'site' for
Perl >= 5.012?

Roughly speaking, I think that would mean the logic should be:

  installdirs => ($] ge $when_added_to_core && $] lt '5.012' ? 'core' : 'site' )

(with my preference for string comparison to avoid 64-bit decimal
equality comparison issues)

Does that make sense?

If so, dual-life maintainers, please double check your Makefile.PL or Build.PL

-- David

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About