Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^2: Error while installing Net::Pcap on Windows Strawberry Perl

by sagarkha (Acolyte)
on Oct 06, 2010 at 23:05 UTC ( #863883=note: print w/ replies, xml ) Need Help??


in reply to Re: Error while installing Net::Pcap on Windows Strawberry Perl
in thread Error while installing Net::Pcap on Windows Strawberry Perl

I think winpcap is already installed in my system becuase i have laready installed Wireshark which uses Pcap. Still i have installed new version of pcap again with the url that you have provided. But again i am getting the same error message

checking for pcap_lib_version() in -lwpcap... no - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - You appear to lack the WinPcap developer pack. If it is installed in a non-standard location, please try setting the +LIBS and INC values on the command line. For instance, if you have unziped + the developer's pack in C:\WpdPack, you should execute: perl Makefile.PL INC=-IC:/WpdPack/Include "LIBS=-LC:/WpdPack/Lib - +lwpcap" Or get and install the WinPcap developer's pack from http://www.winpcap.org/install/ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - detecting available functions... ok Checking if your kit is complete... Looks good Note (probably harmless): No library found for -lwpcap Writing Makefile for Net::Pcap


Comment on Re^2: Error while installing Net::Pcap on Windows Strawberry Perl
Download Code
Re^3: Error while installing Net::Pcap on Windows Strawberry Perl
by syphilis (Canon) on Oct 07, 2010 at 01:14 UTC
    I think winpcap is already installed in my system

    Then it's installed in a location that's not being found by default. You need to follow the advice offered by the error message regarding If it is installed in a non-standard location
    First, cd to the Net::Pcap build directory and run dmake realclean. Then run, as suggested:
    perl Makefile.PL INC=-IC:/WpdPack/Include "LIBS=-IC:/WpdPack/Lib -lwpc +ap"
    You'll need to modify the INC and LIBS paths specified in that command so that they point to the location of the wpcap headers and library on your machine.
    Then run dmake test followed by dmake install

    Cheers,
    Rob

    UPDATE: Give that a try, though I'm now not so sure that's what's needed. I've just noticed this in the message you posted:
    socket.h patched... ok looking for -lwpcap... yes checking for pcap_lib_version() in -lwpcap... no
    So, at some point, wpcap is being found, but that library doesn't provide a pcap_lib_version(). Is your version of that library a recent one ?
Re^3: Error while installing Net::Pcap on Windows Strawberry Perl
by afresh1 (Hermit) on Oct 07, 2010 at 17:49 UTC

    Did you get the "developer pack"? http://www.winpcap.org/devel.htm

    The error does indicate that the developer pack is required and the /install link seems to default to a download that is not the developer pack.

    l8rZ,
    --
    andrew
      I have installed the developer pack now and i think i am very near to solve this problem:
      C:\strawberry\cpan\build\Net-Pcap-0.16-A9_0Y2>perl Makefile.PL INC=-IC +:/WpdPack/ Include "LIBS=-LC:/WpdPack/Lib -lwpcap" Set up gcc environment - 3.4.5 (mingw-vista special r3) Unable to patch socket.h looking for -lwpcap... yes checking for pcap_lib_version() in -lwpcap... yes detecting available functions... ok Writing Makefile for Net::Pcap
      can somebody please tell how to proceed further, if i try to install Net:Pcap through cpan i still get the same error.
      CPAN.pm: Going to build S/SA/SAPER/Net-Pcap-0.16.tar.gz Set up gcc environment - 3.4.5 (mingw-vista special r3) Unable to patch socket.h looking for -lwpcap... yes checking for pcap_lib_version() in -lwpcap... no - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - You appear to lack the WinPcap developer pack. If it is installed in a non-standard location, please try setting the +LIBS and INC values on the command line. For instance, if you have unziped + the developer's pack in C:\WpdPack, you should execute: perl Makefile.PL INC=-IC:/WpdPack/Include "LIBS=-LC:/WpdPack/Lib - +lwpcap" Or get and install the WinPcap developer's pack from http://www.winpcap.org/install/ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - detecting available functions... ok Checking if your kit is complete... Looks good Note (probably harmless): No library found for -lwpcap Writing Makefile for Net::Pcap
        can somebody please tell how to proceed further

        Having run
        perl Makefile.PL INC=-IC:/WpdPack/Include "LIBS=-LC:/WpdPack/Lib -lwpc +ap"
        follow that with dmake test and then dmake install

        I notice that you're now getting "Unable to patch socket.h", presumably because it has already been patched, so I think you can ignore that. If there's any problem with socket.h, it should show up during dmake test anyway.

        If you want to be able to build it with CPAN, add C:/WpdPack/Include to the incpath setting (in perl/lib/Config_heavy.pl) and add C:/WpdPack/Lib to the libpth setting (in both perl/lib/Config_heavy.pl and perl/lib/Config.pm). I think that should work.
        An alternative to messing with incpath is to simply set the CPATH envronment variable:
        set CPATH=C:\WpdPack\Include
        Cheers,
        Rob

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://863883]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (10)
As of 2014-07-25 12:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (171 votes), past polls