[Module::Build] Making 0.28 a reality
Status: Beta
Brought to you by:
kwilliams
|
From: John P. <jpe...@ro...> - 2006-02-18 02:57:42
|
Folks -
What can I do to help get 0.28 out the door. I was using 0.27_07 and released
version-0.54 to CPAN and promptly broke every module trying to upgrade that
depends on version due to a limitation in 0.2611. It seems that
have_c_compiler() depends on _build/ existing, yet _build/ isn't created until
you call create_build_script() which I wasn't doing until after I found out
whether there was a compiler available. Chicken <=> Egg. Needless to say,
version-0.55 is out now. :(
I know, *my fault*, not Module::Build's, but still, it makes me want to use
Module::Install now... ;-)
Where we left the earlier discussion was that the version.pm patch to M::B would
require upgrading the YAML dependency to 0.58. The issue was that this would
[mostly] silently disable the YAML support for people who didn't notice. There
seems to be two ways around it:
1) write a routine to query the user whether they wanted to upgrade YAML at the
same time and then make it a prereq;
or
2) just go ahead and make YAML a prereq of 0.28.
Is there any reason why #2 isn't the way to go? Is M::B really wedded to the
_write_minimal_metadata code for some reason? Isn't YAML stable enough? YAML
doesn't appear to have any non-core dependencies (according to module_info):
Modules used:
YAML::Base
YAML::Dumper::Base
YAML::Node
base
constant
strict
warnings
That would certainly be the cleanest way to deal with it.
As a third option, if I had to, I could produce a patch that would force the
version objects to stringify before being added to the YAML $node. But this is
especially ugly and hackish.
Note also that I forgot this on my previous patch:
$ svk diff lib/Module/Build/Base.pm
=== lib/Module/Build/Base.pm
==================================================================
--- lib/Module/Build/Base.pm (revision 1830)
+++ lib/Module/Build/Base.pm (local)
@@ -1090,10 +1090,6 @@
my $self = shift;
my ($v1, $op, $v2) = @_;
- # for alpha versions - this doesn't cover all cases, but should work for most:
- $v1 =~ s/_(\d+)\z/$1/;
- $v2 =~ s/_(\d+)\z/$1/;
-
my $eval_str = "\$v1 $op \$v2";
my $result = eval $eval_str;
$self->log_warn("error comparing versions: '$eval_str' $@") if $@;
since version objects work fine as alpha versions. After 0.28 is out, I can
move more of the version code to Module::Build::version and simplify a lot of
code in the process.
John
--
John Peacock
Director of Information Research and Technology
Rowman & Littlefield Publishing Group
4720 Boston Way
Lanham, MD 20706
301-459-3366 x.5010
fax 301-429-5747
|