On Jan 27, 2005, at 3:56 AM, Jos I. Boumans wrote:
On Jan 26, 2005, at 9:00 PM, Ken Williams wrote:
On Jan 25, 2005, at 3:26 PM, John Peacock wrote:
Jos I. Boumans wrote:I suppose if Module::Build::Base would say, at the top:
$VERSION = $Module::Build::VERSION
this would make EU::MM, M::IV, M::L::C and of course CPANPLUS::inc find a 'real' version declaration, rather than something evil that will blow away UNIVERSAL::VERSION.
Yes, that would be an appropriate fix to M::B::Base.
That won't work. All those tools evaluate the version line in isolation, not by loading the modules and checking the value of $VERSION. In other words, when Module::Build::Base's version is checked, Module::Build won't be loaded, so the version would be undef.
Well, the above one line fix adresses 2 issues, and they both 'do work':
1) Under normal operation, M::B::Base is loaded from M::B, so the $VERSION variable would be defined. Anyone using M::B programatically
would find what is expected.
Right.
2) All tools using the EU::MM 'standard' regex would find a valid version
declaration.
Except that it won't have the right value, it'll be undef. Tools like the META.yml builders, search.cpan.org, etc. that report versions of modules would all be fooled.
I think the only sane fix here is to make sure that whatever code, be it in M::B or CP+ or perl, is evaluating these lines, doesn't cause a segfault when it makes a mistake. Bad version lines are always going to be out there, even if we legislate against them.
As for M::B, of course I can change it, and I suppose I probably should. Split that code over two lines or something.
-Ken
smime.p7s
Description: S/MIME cryptographic signature
