Skip Menu |
 

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Devel-Cover CPAN distribution.

Report information
The Basics
Id: 29362
Status: resolved
Priority: 0/
Queue: Devel-Cover

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

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



Subject: gcov2perl improvement
Download (untitled) / with headers
text/plain 367b
Currently, gcov2perl searches the source file in the same directory as the .gcov file. But .o & .gcov could be build in a different directory of the source directory (especially in pure C project). This issue could be easily fixed, because the first line of gcov file contains the full path of the source file. See the following patch. Regards. François Perrad.
Subject: gcov2perl.patch
Download gcov2perl.patch
text/x-diff 869b
Index: gcov2perl =================================================================== --- gcov2perl (revision 250) +++ gcov2perl (working copy) @@ -53,11 +53,11 @@ $run{collected} = ["statement"]; my $structure = Devel::Cover::DB::Structure->new; $structure->add_criteria("statement"); - $run{digests}{$f} = $structure->set_file($f); open F, $file or die "Can't open $file: $!\n"; while (<F>) { + $f = $1 if /^[^:]+:[^:]+:Source:(.*)$/; next unless my ($count, $line) = /(.{9}):\s*(\d+):/; $count =~ s/\s+//g; next if $count eq "-"; @@ -69,6 +69,8 @@ } close F or die "Can't close $file: $!\n"; + $run{digests}{$f} = $structure->set_file($f); + my $run = time . ".$$." . sprintf "%05d", rand 2 ** 16; my $db = $Options->{db}; my $cover = Devel::Cover::DB->new
Download (untitled) / with headers
text/plain 173b
I think I applied this a long time ago but forgot to say anything about it or to close the ticket. I'm very sorry about that so please accept a belated: Applied, thanks.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.