waytoperl has asked for the wisdom of the Perl Monks concerning the following question:

I'm trying to install Net::Pcap and CPAN is throwing error with Failed test and not able to install. I'm going nuts with this error. Tried to upgrade CPAN by
cpan cpan [1]> upgrade

Replies are listed 'Best First'.
Re: Not able to install Net::Pcap in MAC OS Mavericks
by Anonymous Monk on Jul 21, 2014 at 10:09 UTC

    yeah, start with  cpan> look Net::Pcap and follow the README

    When you encounter an error, report it

Re: Not able to install Net::Pcap in MAC OS Mavericks
by jeffa (Bishop) on Jul 21, 2014 at 16:36 UTC

    I was able to get this to install on my Mac (using Perlbrew and cpanm with the --notest option). Looks like the tests failed here:

    # libpcap version 1.3.0 - Apple version 41 # Failed test ' - checking version string (libpcap version 1.3.0 - A +pple version 41)' # at t/17-lib_version.t line 17. # 'libpcap version 1.3.0 - Apple version 41' # doesn't match '/^libpcap version (?:\d+\.\d+(?:\.\d+|[^\d.\s]+)? +|unknown \(pre 0\.8\))$/' # Looks like you failed 1 test of 2. t/17-lib_version.t .........

    There might be an incompatibility issue with the lib versions, but i would try installing without testing or installing by force and see if your code works.

    jeffa

    L-LL-L--L-LL-L--L-LL-L--
    -R--R-RR-R--R-RR-R--R-RR
    B--B--B--B--B--B--B--B--
    H---H---H---H---H---H---
    (the triplet paradiddle with high-hat)
    
      I'm encountering same issue in MAC OS x 10.9.
      'libpcap version 1.3.0 - Apple version 41'
      Somewhere in online they have mentioned MAC OS has pre-installed Perl modules in
      ~/Library/Perl
Re: Not able to install Net::Pcap in MAC OS Mavericks
by jellisii2 (Hermit) on Jul 21, 2014 at 11:27 UTC
    Perlbrew may be your friend here. On the home page, they even reference where Apple hosed updates to perl.