X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=lib%2FCPANPLUS%2FDist%2FGentoo.pm;h=177c70f91df1e6db4d1c5b94442fa504d3d2b9be;hb=bad6ecaf3e526f13b487fac29c30c048d1252b42;hp=d706de32bb0d45c3b7e086ccfaf44bf6550966fb;hpb=fa5334799838382278e1c11242e94f09e9518e3d;p=perl%2Fmodules%2FCPANPLUS-Dist-Gentoo.git diff --git a/lib/CPANPLUS/Dist/Gentoo.pm b/lib/CPANPLUS/Dist/Gentoo.pm index d706de3..177c70f 100644 --- a/lib/CPANPLUS/Dist/Gentoo.pm +++ b/lib/CPANPLUS/Dist/Gentoo.pm @@ -22,11 +22,11 @@ CPANPLUS::Dist::Gentoo - CPANPLUS backend generating Gentoo ebuilds. =head1 VERSION -Version 0.06 +Version 0.07 =cut -our $VERSION = '0.06'; +our $VERSION = '0.07'; =head1 SYNOPSIS @@ -84,22 +84,22 @@ sub format_available { } if (IPC::Cmd->can_capture_buffer) { - my ($success, $errmsg, $output) = run command => [ qw/emerge --info/ ], - verbose => 0; + my $buffers; + my ($success, $errmsg) = run command => [ qw/emerge --info/ ], + verbose => 0, + buffer => \$buffers; if ($success) { - for (@{$output || []}) { - if (/^PORTDIR_OVERLAY=(.*)$/m) { - $overlays = [ map abs_path($_), split ' ', _unquote($1) ]; - } - if (/^ACCEPT_KEYWORDS=(.*)$/m) { - $default_keywords = [ split ' ', _unquote($1) ]; - } - if (/^DISTDIR=(.*)$/m) { - $default_distdir = abs_path(_unquote($1)); - } - if (/^PORTDIR=(.*)$/m) { - $main_portdir = abs_path(_unquote($1)); - } + if ($buffers =~ /^PORTDIR_OVERLAY=(.*)$/m) { + $overlays = [ map abs_path($_), split ' ', _unquote($1) ]; + } + if ($buffers =~ /^ACCEPT_KEYWORDS=(.*)$/m) { + $default_keywords = [ split ' ', _unquote($1) ]; + } + if ($buffers =~ /^DISTDIR=(.*)$/m) { + $default_distdir = abs_path(_unquote($1)); + } + if ($buffers =~ /^PORTDIR=(.*)$/m) { + $main_portdir = abs_path(_unquote($1)); } } else { error $errmsg;