diff --git a/Changes b/Changes index 455eace..cf36cb9 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,15 @@ Revision history for ELF-Extract-Sections +1.001003 2015-09-27T08:06:04Z 55e4d01 + [Dependencies::Stats] + - Dependencies changed since 1.001002, see misc/*.deps* for details + - runtime: +1 + - test: -1 + + [Win32 Support] + - Handle reading from objdump using slurp style IO instead of using an IO Handle due to open '-|', @list not being + reliable on Win32. + 1.001002 2015-09-27T07:39:23Z f807e17 [Installation] - Checks now attempt to extract the version itself from the version string and versions prior to 2.17 are now all diff --git a/META.json b/META.json index dcd660c..44ac346 100644 --- a/META.json +++ b/META.json @@ -104,6 +104,7 @@ "Moose" : "2.000" }, "requires" : { + "Capture::Tiny" : "0", "Carp" : "0", "Log::Log4perl" : "1.21", "Module::Runtime" : "0", @@ -129,7 +130,6 @@ "Test::More" : "0.99" }, "requires" : { - "Capture::Tiny" : "0", "ExtUtils::MakeMaker" : "0", "File::Spec" : "0", "File::Which" : "0", @@ -147,23 +147,23 @@ "provides" : { "ELF::Extract::Sections" : { "file" : "lib/ELF/Extract/Sections.pm", - "version" : "1.001002" + "version" : "1.001003" }, "ELF::Extract::Sections::Meta::Scanner" : { "file" : "lib/ELF/Extract/Sections/Meta/Scanner.pm", - "version" : "1.001002" + "version" : "1.001003" }, "ELF::Extract::Sections::Meta::Types" : { "file" : "lib/ELF/Extract/Sections/Meta/Types.pm", - "version" : "1.001002" + "version" : "1.001003" }, "ELF::Extract::Sections::Scanner::Objdump" : { "file" : "lib/ELF/Extract/Sections/Scanner/Objdump.pm", - "version" : "1.001002" + "version" : "1.001003" }, "ELF::Extract::Sections::Section" : { "file" : "lib/ELF/Extract/Sections/Section.pm", - "version" : "1.001002" + "version" : "1.001003" } }, "release_status" : "testing", @@ -178,7 +178,7 @@ "web" : "https://github.com/kentnl/ELF-Extract-Sections" } }, - "version" : "1.001002", + "version" : "1.001003", "x_BuiltWith" : { "external_file" : "misc/built_with.json" }, @@ -674,7 +674,7 @@ "branch" : null, "changelog" : "Changes", "signed" : 0, - "tag" : "1.001002-source", + "tag" : "1.001003-source", "tag_format" : "%v-source", "tag_message" : "v%v" }, @@ -765,7 +765,7 @@ "branch" : "releases", "changelog" : "Changes", "signed" : 0, - "tag" : "1.001002", + "tag" : "1.001003", "tag_format" : "%v", "tag_message" : "v%v" }, diff --git a/META.yml b/META.yml index f049c64..c6aea2e 100644 --- a/META.yml +++ b/META.yml @@ -3,7 +3,6 @@ abstract: 'Extract Raw Chunks of data from identifiable ELF Sections' author: - 'Kent Fredric ' build_requires: - Capture::Tiny: '0' ExtUtils::MakeMaker: '0' File::Spec: '0' File::Which: '0' @@ -31,22 +30,23 @@ name: ELF-Extract-Sections provides: ELF::Extract::Sections: file: lib/ELF/Extract/Sections.pm - version: '1.001002' + version: '1.001003' ELF::Extract::Sections::Meta::Scanner: file: lib/ELF/Extract/Sections/Meta/Scanner.pm - version: '1.001002' + version: '1.001003' ELF::Extract::Sections::Meta::Types: file: lib/ELF/Extract/Sections/Meta/Types.pm - version: '1.001002' + version: '1.001003' ELF::Extract::Sections::Scanner::Objdump: file: lib/ELF/Extract/Sections/Scanner/Objdump.pm - version: '1.001002' + version: '1.001003' ELF::Extract::Sections::Section: file: lib/ELF/Extract/Sections/Section.pm - version: '1.001002' + version: '1.001003' recommends: Moose: '2.000' requires: + Capture::Tiny: '0' Carp: '0' Log::Log4perl: '1.21' Module::Runtime: '0' @@ -66,4 +66,4 @@ resources: bugtracker: https://github.com/kentnl/ELF-Extract-Sections/issues homepage: https://github.com/kentnl/ELF-Extract-Sections repository: https://github.com/kentnl/ELF-Extract-Sections.git -version: '1.001002' +version: '1.001003' diff --git a/Makefile.PL b/Makefile.PL index a2346e4..b6e96fe 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -20,6 +20,7 @@ my %WriteMakefileArgs = ( "MIN_PERL_VERSION" => "5.010000", "NAME" => "ELF::Extract::Sections", "PREREQ_PM" => { + "Capture::Tiny" => 0, "Carp" => 0, "Log::Log4perl" => "1.21", "Module::Runtime" => 0, @@ -36,7 +37,6 @@ my %WriteMakefileArgs = ( "warnings" => 0 }, "TEST_REQUIRES" => { - "Capture::Tiny" => 0, "ExtUtils::MakeMaker" => 0, "File::Spec" => 0, "File::Which" => 0, @@ -48,7 +48,7 @@ my %WriteMakefileArgs = ( "YAML::XS" => 0, "lib" => 0 }, - "VERSION" => "1.001002", + "VERSION" => "1.001003", "test" => { "TESTS" => "t/*.t t/00-compile/*.t" } diff --git a/lib/ELF/Extract/Sections.pm b/lib/ELF/Extract/Sections.pm index 27d4856..32c74a0 100644 --- a/lib/ELF/Extract/Sections.pm +++ b/lib/ELF/Extract/Sections.pm @@ -6,7 +6,7 @@ package ELF::Extract::Sections; # ABSTRACT: Extract Raw Chunks of data from identifiable ELF Sections -our $VERSION = '1.001002'; # TRIAL +our $VERSION = '1.001003'; # TRIAL our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY @@ -267,7 +267,7 @@ ELF::Extract::Sections - Extract Raw Chunks of data from identifiable ELF Sectio =head1 VERSION -version 1.001002 +version 1.001003 =head1 SYNOPSIS diff --git a/lib/ELF/Extract/Sections/Meta/Scanner.pm b/lib/ELF/Extract/Sections/Meta/Scanner.pm index 79b538f..c4eb1a6 100644 --- a/lib/ELF/Extract/Sections/Meta/Scanner.pm +++ b/lib/ELF/Extract/Sections/Meta/Scanner.pm @@ -6,7 +6,7 @@ package ELF::Extract::Sections::Meta::Scanner; # ABSTRACT: Interface Contract for Scanners -our $VERSION = '1.001002'; # TRIAL +our $VERSION = '1.001003'; # TRIAL our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY @@ -36,7 +36,7 @@ ELF::Extract::Sections::Meta::Scanner - Interface Contract for Scanners =head1 VERSION -version 1.001002 +version 1.001003 =head1 Required Methods for Applying Roles diff --git a/lib/ELF/Extract/Sections/Meta/Types.pm b/lib/ELF/Extract/Sections/Meta/Types.pm index db42650..ff9d56f 100644 --- a/lib/ELF/Extract/Sections/Meta/Types.pm +++ b/lib/ELF/Extract/Sections/Meta/Types.pm @@ -6,7 +6,7 @@ package ELF::Extract::Sections::Meta::Types; # ABSTRACT: Generic Type Constraints for E:E:S -our $VERSION = '1.001002'; # TRIAL +our $VERSION = '1.001003'; # TRIAL our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY @@ -32,7 +32,7 @@ ELF::Extract::Sections::Meta::Types - Generic Type Constraints for E:E:S =head1 VERSION -version 1.001002 +version 1.001003 =head1 Types diff --git a/lib/ELF/Extract/Sections/Scanner/Objdump.pm b/lib/ELF/Extract/Sections/Scanner/Objdump.pm index b840544..28fbd97 100644 --- a/lib/ELF/Extract/Sections/Scanner/Objdump.pm +++ b/lib/ELF/Extract/Sections/Scanner/Objdump.pm @@ -6,7 +6,7 @@ package ELF::Extract::Sections::Scanner::Objdump; # ABSTRACT: An objdump based section scanner. -our $VERSION = '1.001002'; # TRIAL +our $VERSION = '1.001003'; # TRIAL our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY @@ -173,12 +173,33 @@ sub _build__section_header_identifier { return qr/${header}\s*${offset}:/; } +sub _objdump_win32 { + my ($self) = @_; + require Capture::Tiny; + ## no critic (Subroutines::ProhibitCallsToUnexportedSubs) + my ( $stdout, $result ) = Capture::Tiny::capture_stdout( + sub { + system 'objdump', qw( -D -F ), $self->_file->realpath->absolute; + }, + ); + if ( $result != 0 ) { + $self->log->logconfess(qq{An error occured requesting section data from objdump $^E $@ }); + } + open my $fh, '<', \$stdout or do { + $self->log->logconfess(qq{An error occured making a string IO filehandle $! $@ }); + }; + return $fh; +} + sub _objdump { my ($self) = @_; + if ( 'MSWin32' eq $^O or $ENV{OBJDUMP_SLURP} ) { + return $self->_objdump_win32; + } if ( open my $fh, q{-|}, q{objdump}, qw( -D -F ), $self->_file->realpath->absolute ) { return $fh; } - $self->log->logconfess(qq{An error occured requesting section data from objdump $^ $@ }); + $self->log->logconfess(qq{An error occured requesting section data from objdump $! $@ }); return; } @@ -196,7 +217,7 @@ ELF::Extract::Sections::Scanner::Objdump - An objdump based section scanner. =head1 VERSION -version 1.001002 +version 1.001003 =head1 SYNOPSIS diff --git a/lib/ELF/Extract/Sections/Section.pm b/lib/ELF/Extract/Sections/Section.pm index 7d3d57d..24aa460 100644 --- a/lib/ELF/Extract/Sections/Section.pm +++ b/lib/ELF/Extract/Sections/Section.pm @@ -6,7 +6,7 @@ package ELF::Extract::Sections::Section; # ABSTRACT: An Objective reference to a section in an ELF file. -our $VERSION = '1.001002'; # TRIAL +our $VERSION = '1.001003'; # TRIAL our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY @@ -189,7 +189,7 @@ ELF::Extract::Sections::Section - An Objective reference to a section in an ELF =head1 VERSION -version 1.001002 +version 1.001003 =head1 SYNOPSIS diff --git a/misc/Changes.deps b/misc/Changes.deps index 49dff4f..38eeae8 100644 --- a/misc/Changes.deps +++ b/misc/Changes.deps @@ -1,6 +1,13 @@ This file contains changes in REQUIRED dependencies for standard CPAN phases (configure/build/runtime/test) -1.001002 +1.001003 + [Added / runtime requires] + - Capture::Tiny + + [Removed / test requires] + - Capture::Tiny + +1.001002 2015-09-27T07:39:23Z 1.001001 2015-09-26T06:22:10Z [Added / configure requires] diff --git a/misc/Changes.deps.all b/misc/Changes.deps.all index 3f69be1..0febc9c 100644 --- a/misc/Changes.deps.all +++ b/misc/Changes.deps.all @@ -1,6 +1,13 @@ This file contains ALL changes in dependencies in both REQUIRED / OPTIONAL dependencies for all phases (configure/build/runtime/test/develop) -1.001002 +1.001003 + [Added / runtime requires] + - Capture::Tiny + + [Removed / test requires] + - Capture::Tiny + +1.001002 2015-09-27T07:39:23Z 1.001001 2015-09-26T06:22:10Z [Added / configure requires] diff --git a/misc/Changes.deps.dev b/misc/Changes.deps.dev index c30b5c0..0c55574 100644 --- a/misc/Changes.deps.dev +++ b/misc/Changes.deps.dev @@ -1,6 +1,8 @@ This file contains changes to DEVELOPMENT dependencies only ( both REQUIRED and OPTIONAL ) -1.001002 +1.001003 + +1.001002 2015-09-27T07:39:23Z 1.001001 2015-09-26T06:22:10Z [Added / develop requires] diff --git a/misc/Changes.deps.opt b/misc/Changes.deps.opt index 31ed2e1..a7a7458 100644 --- a/misc/Changes.deps.opt +++ b/misc/Changes.deps.opt @@ -1,6 +1,8 @@ This file contains changes in OPTIONAL dependencies for standard CPAN phases (configure/build/runtime/test) -1.001002 +1.001003 + +1.001002 2015-09-27T07:39:23Z 1.001001 2015-09-26T06:22:10Z diff --git a/t/00-report-prereqs.dd b/t/00-report-prereqs.dd index ca11994..fb0d37e 100644 --- a/t/00-report-prereqs.dd +++ b/t/00-report-prereqs.dd @@ -89,6 +89,7 @@ do { my $x = { 'Moose' => '2.000' }, 'requires' => { + 'Capture::Tiny' => '0', 'Carp' => '0', 'Log::Log4perl' => '1.21', 'Module::Runtime' => '0', @@ -114,7 +115,6 @@ do { my $x = { 'Test::More' => '0.99' }, 'requires' => { - 'Capture::Tiny' => '0', 'ExtUtils::MakeMaker' => '0', 'File::Spec' => '0', 'File::Which' => '0',