Skip Menu |

This queue is for tickets about the Locale-Codes CPAN distribution.

Report information
The Basics
Id: 123571
Status: resolved
Priority: 0/
Queue: Locale-Codes

People
Owner: Nobody in particular
Requestors: DBOOK [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Distribution should install to sitelib on perl 5.12+
The Makefile.PL will set INSTALLDIRS to 'perl' on perls > 5.7.3, as that's where at least some part of this distribution was added to core: https://metacpan.org/source/SBECK/Locale-Codes-3.54/Makefile.PL#L192 This is correct, and works around the issue in older perls where privlib (or the 'perl' core install dir) is checked first for modules before sitelib (where CPAN normally installs to). Unfortunately this means it overwrites any existing files that were installed with core but it's the only way to allow module upgrades on these versions of perl. However in perl 5.12 this order was changed so that sitelib takes precedence. Therefore the distribution should install to sitelib as normal on these versions, rather than overwriting the core files. For example: INSTALLDIRS => (($] >= 5.007003 && $] < 5.012) ? 'perl' : 'site'), (ref: https://metacpan.org/source/CORION/parent-0.236/Makefile.PL#L16-19 ) The Build.PL should also be updated with similar logic since it will be the file used on any modern perl, I'm not familiar with any other dual-life distributions using Build.PL but I would guess it should be like: installdirs => (($] < 5.012) ? 'core' : 'site'), (ref: https://metacpan.org/pod/Module::Build::API#installdirs ) This change should be made regardless of whether the distribution remains in core in the future, but especially if it doesn't. Installation to perls before 5.12 should remain unaffected but installation to newer perls will install to sitelib like any other CPAN module.
This will be fixed in the next release (due out in a couple weeks).