p5-Devel-Cover lacks prerequisite B::Debug

From: James E Keenan <jkeenan_at_pobox.com>
Date: Tue, 24 Aug 2021 15:08:43 UTC
Today I attempted to install FreeBSD port 'p5-Devel-Cover' on 
FreeBSD-12.  The system 'perl' on this machine was perl-5.32.0.  I ran 
into problems which suggest that the p5-Devel-Cover port needs revision.

#####
$ uname -mrs
FreeBSD 12.2-STABLE amd64

$ sudo pkg install p5-Devel-Cover
Password:
Updating FreeBSD repository catalogue...
Fetching packagesite.pkg: 100%    6 MiB   6.6MB/s    00:01
Processing entries: 100%
FreeBSD repository update completed. 30986 packages processed.
All repositories are up to date.
The following 5 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
	p5-Devel-Cover: 1.36
	p5-Devel-Symdump: 2.1800
	p5-Parallel-Iterator: 1.00_1
	p5-Pod-Coverage: 0.23_2
	p5-Pod-Parser: 1.63_1

Number of packages to be installed: 5

301 KiB to be downloaded.

Proceed with this action? [y/N]: y
[1/5] Fetching p5-Devel-Cover-1.36.pkg: 100%  174 KiB 177.9kB/s    00:01
... snip
[5/5] Installing p5-Devel-Cover-1.36...
[5/5] Extracting p5-Devel-Cover-1.36: 100%
#####

So far, so good -- but when I went to run 'cover' on a Perl library I've 
written, I got:

#####
$ cover -delete; harness; cover -report=text > 
$P5P_DIR/multisect/`extract-sha`.coverage.txt

This version of Devel::Cover was built with Perl version 5.032001.
It is now being run with Perl version 5.032000.
Attempting to make adjustments, but you may find that some of your 
modules do
not have coverage data collected.  You may need to alter the +-inc, +-ignore
and +-select options.

Deleting database /usr/home/jkeenan/gitwork/devel-git-multibisect/cover_db
PERL_DL_NONLAZY=1 "/usr/local/bin/perl" "-MExtUtils::Command::MM" 
"-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 
'blib/lib', 'blib/arch')" t/*.t
t/001-opts.t .....................
This version of Devel::Cover was built with Perl version 5.032001.
It is now being run with Perl version 5.032000.
Attempting to make adjustments, but you may find that some of your 
modules do
not have coverage data collected.  You may need to alter the +-inc, +-ignore
and +-select options.

Can't locate B/Debug.pm in @INC (you may need to install the B::Debug 
module) (@INC contains: 
/usr/home/jkeenan/gitwork/devel-git-multibisect/blib/lib 
/usr/home/jkeenan/gitwork/devel-git-multibisect/blib/arch 
/usr/local/lib/perl5/site_perl/mach/5.32 /usr/local/lib/perl5/site_perl 
/usr/local/lib/perl5/5.32/mach /usr/local/lib/perl5/5.32 .) at 
/usr/local/lib/perl5/site_perl/mach/5.32/Devel/Cover.pm line 28.
BEGIN failed--compilation aborted at 
/usr/local/lib/perl5/site_perl/mach/5.32/Devel/Cover.pm line 28.
Compilation failed in require.
BEGIN failed--compilation aborted.
t/001-opts.t ..................... Dubious, test returned 2 (wstat 512, 
0x200)
No subtests run
...
[snip: all other test files fail in the same way]
#####

I addressed the Perl version clash by upgrading the 'perl5' package to 
5.32.1.  That proceeded without incident.

I then looked at the apparently missing prerequisite B::Debug.  The 
'corelist' utility tells me that this module no longer ships with the 
Perl 5 core distribution:

#####
$ corelist B::Debug

Data for 2020-06-20
B::Debug was first released with perl 5.005, deprecated (will be 
CPAN-only) in v5.27.3 and removed from v5.29.4
#####

I searched for B-Debug at FreeBSD Ports Search, but no Perl 5 program 
was listed.

#####
https://www.freebsd.org/cgi/ports.cgi?query=B-Debug&stype=all&sektion=all
#####

I then installed B::Debug directly from CPAN.  It installed successfully 
... and then to my surprise subsequently installed B::Flags in the same 
'cpan' session.

#####
   RURBAN/B-Debug-1.26.tar.gz
   /usr/bin/make install  -- OK
...
   RURBAN/B-Flags-0.17.tar.gz
   /usr/bin/make install  -- OK
#####

It turns out that there *does* exist a FreeBSD port for B::Flags:

#####
https://cgit.freebsd.org/ports/tree/devel/p5-B-Flags
#####

... but this *does not* appear to include B::Debug.

Action Items

1. There should be a FreeBSD port for CPAN distribution B-Debug.

2. The FreeBSD port for Devel-Cover (p5-Devel-Cover) needs to have a 
prerequisite added for the port for B-Debug requested in the preceding item.

Thank you very much.
Jim Keenan