Skip Menu |

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

Report information
The Basics
Id: 24772
Status: new
Priority: 0/
Queue: Module-Depends

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

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



Subject: recommends section support
Module::Build and Module::Install have 'recommends' sections. It'd be helpful if Module::Depends lists them as well. Patch Attached, though this is one for prestine MD 0.11 without applying previous patch to fix no-such-dir problem.
Subject: MD-recommends.patch
diff -ur Module-Depends-0.11/lib/Module/Depends/Intrusive.pm Module-Depends-0.11-recommends/lib/Module/Depends/Intrusive.pm --- Module-Depends-0.11/lib/Module/Depends/Intrusive.pm 2007-02-03 14:16:40.000000000 +0900 +++ Module-Depends-0.11-recommends/lib/Module/Depends/Intrusive.pm 2007-02-04 00:33:50.307250000 +0900 @@ -32,6 +32,7 @@ my %args = @_; $self->requires( $args{requires} || {} ); $self->build_requires( $args{build_requires} || {} ); + $self->recommends( $args{recommends} || {} ); bless {}, "Module::Depends::Intrusive::Fake::Module::Build"; }; local *Module::Build::subclass = sub { 'Module::Build' }; @@ -74,6 +75,10 @@ my %deps = (@_ == 1 ? ( $_[0] => 0 ) : @_); $self->build_requires->{ $_ } = $deps{ $_ } for keys %deps; }; + local *inc::Module::Install::recommends = sub { + my %deps = (@_ == 1 ? ( $_[0] => 0 ) : @_); + $self->recommends->{ $_ } = $deps{ $_ } for keys %deps; + }; my $file = File::Spec->catfile( getcwd(), $pl ); eval { diff -ur Module-Depends-0.11/lib/Module/Depends.pm Module-Depends-0.11-recommends/lib/Module/Depends.pm --- Module-Depends-0.11/lib/Module/Depends.pm 2007-02-03 14:16:40.000000000 +0900 +++ Module-Depends-0.11-recommends/lib/Module/Depends.pm 2007-02-04 00:32:52.385375000 +0900 @@ -4,7 +4,7 @@ use Cwd qw( getcwd ); use base qw( Class::Accessor::Chained ); use File::chdir; -__PACKAGE__->mk_accessors(qw( dist_dir debug libs requires build_requires error )); +__PACKAGE__->mk_accessors(qw( dist_dir debug libs requires build_requires recommends error )); our $VERSION = '0.11'; =head1 NAME @@ -43,6 +43,7 @@ libs => [], requires => {}, build_requires => {}, + recommends => {}, error => '', }); } @@ -78,6 +79,7 @@ my $meta = LoadFile( $file ); $self->requires( $meta->{requires} ); $self->build_requires( $meta->{build_requires} ); + $self->recommends( $meta->{recommends} ); } else { $self->error( "No META.yml found in ". $self->dist_dir );