Skip Menu |

This queue is for tickets about the Module-Release CPAN distribution.

Report information
The Basics
Id: 46696
Status: resolved
Priority: 0/
Queue: Module-Release

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

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



Subject: makefile_PL flag not honored and svn status incorrectly parsed [patch]
I really like the v2.0 changes to work with multiple vcs and the built in support for Module::Build, but I found a few bugs when working with svn and Module::Build. 1) Setting the makefile_PL, makefile and make flags in .releaserc doesn't seem to have any impact. I added code in the patch to update $self->{Makefile.PL/Makefile/make} based on the $self->config values. 2) The regex that parses the svn status output isn't treating the multi-line string correctly. The ^ needs to be moved to line where the comparison is made or the m flag needs to be moved to the regex definition. I did the latter in the patch. I also removed an erroneous, duplicate comment from the release script. Thanks for the really convenient module. -Mark
Subject: module-release-build-svn-20090605.patch
diff --git a/lib/Release.pm b/lib/Release.pm index 68264ef..51cfba4 100644 --- a/lib/Release.pm +++ b/lib/Release.pm @@ -271,6 +271,12 @@ sub _process_configuration $self->{passive_ftp} = ($self->config->passive_ftp && $self->config->passive_ftp =~ /^y(es)?/) ? 1 : 0; + $self->{'Makefile.PL'} = $self->config->get('makefile_PL') + if $self->config->exists('makefile_PL'); + $self->{Makefile} = $self->config->get('makefile') + if $self->config->exists('makefile'); + $self->{make} = $self->config->get('make') if $self->config->exists('make'); + my @required = qw( ); my $ok = 1; diff --git a/lib/SVN.pm b/lib/SVN.pm index 994f09e..ce2048f 100644 --- a/lib/SVN.pm +++ b/lib/SVN.pm @@ -70,13 +70,13 @@ sub check_vcs $svn_update =~ s/^(........)\s+\d+\s+\d+\s+\S+\s+(.*)$/$1 $2/mg; my %message = ( - qr/^C......./ => 'These files have conflicts', - qr/^M......./ => 'These files have not been checked in', - qr/^........\*/ => 'These files need to be updated', - qr/^P......./ => 'These files need to be patched', - qr/^A......./ => 'These files were added but not checked in', - qr/^D......./ => 'These files are scheduled for deletion', - qr/^\?......./ => 'I don\'t know about these files', + qr/^C......./m => 'These files have conflicts', + qr/^M......./m => 'These files have not been checked in', + qr/^........\*/m => 'These files need to be updated', + qr/^P......./m => 'These files need to be patched', + qr/^A......./m => 'These files were added but not checked in', + qr/^D......./m => 'These files are scheduled for deletion', + qr/^\?......./m => 'I don\'t know about these files', ); my @svn_states = keys %message; @@ -84,7 +84,7 @@ sub check_vcs my %svn_state; foreach my $state (@svn_states) { - $svn_state{$state} = [ $svn_update =~ /$state\s+(.*)/gm ]; + $svn_state{$state} = [ $svn_update =~ /$state\s+(.*)/g ]; } my $count; diff --git a/script/release b/script/release index 0677111..d599cd7 100755 --- a/script/release +++ b/script/release @@ -352,8 +352,6 @@ if( $release->config->cpan_user ) # not a dry run } -# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # -# Will we upload to PAUSE? $release->load_mixin( 'Module::Release::Prereq' ); my $skip_prereqs = $opts{p} || $release->config->skip_prereqs;
On Fri Jun 05 19:12:28 2009, MGRIMES wrote: Show quoted text
> 1) Setting the makefile_PL, makefile and make flags in .releaserc > doesn't seem to have any impact. I added code in the patch to update > $self->{Makefile.PL/Makefile/make} based on the $self->config values.
Are you just trying to set arguments to these, or are you trying to use something like dmake or gmake? I'd like to keep the arguments separate like CPAN.pm does, maybe like: make gmake makefile Gmakefile make_args ... makepl_args INSTALL_BASE=~ Module::Build would have it's corresponding set of options. Show quoted text
> 2) The regex that parses the svn status output isn't treating the > multi-line string correctly.
I noticed that the other day when I had to actually use SVN. Oh, the good old days :) Thanks,
On Tue Jun 09 03:24:51 2009, BDFOY wrote: Show quoted text
> On Fri Jun 05 19:12:28 2009, MGRIMES wrote: >
> > 1) Setting the makefile_PL, makefile and make flags in .releaserc > > doesn't seem to have any impact. I added code in the patch to update > > $self->{Makefile.PL/Makefile/make} based on the $self->config
> values. > > Are you just trying to set arguments to these, or are you trying to > use something like > dmake or gmake?
Looking at it again, I think you're just trying to use a stupid way I set up to handle Module::Build. The changes will make it into github tonight, and then in the next release. I want to think about that arguments feature for a bit though. You should be safe if you modified your local copy.
Subject: Re: [rt.cpan.org #46696] makefile_PL flag not honored and svn status incorrectly parsed [patch]
Date: Tue, 9 Jun 2009 08:24:59 -0700
To: bug-Module-Release [...] rt.cpan.org
From: Mark Grimes <mgrimes [...] cpan.org>
On Tue, Jun 9, 2009 at 12:44 AM, brian d foy via RT<bug-Module-Release@rt.cpan.org> wrote: Show quoted text
> Looking at it again, I think you're just trying to use a stupid way I set up to handle > Module::Build. The changes will make it into github tonight, and then in the next release. I > want to think about that arguments feature for a bit though.
Yes, I was just trying to use Module::Build. I set the following in .releaserc: makefile_PL Build.PL makefile Build make perl Build I really didn't look at or think about makepl_args when I was looking at the code. Thanks
Fixed in 2.05. Thanks,