Changeset 2024

Show
Ignore:
Timestamp:
05/06/08 12:39:35 (7 months ago)
Author:
aturner
Message:

svn merge -r 2021:2023.
fixes #123, #304, #305

Location:
branches/3.3
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • branches/3.3/docs/Win32Readme.txt

    r1940 r2024  
    3636 
    3737******************************* IMPORTANT ****************************** 
    38 Note: People have reported problems with WpdPack (the developer pack for 
     38Note 1:  
     39People have reported problems with WpdPack (the developer pack for 
    3940Winpcap) being installed outside of the Cygwin root directory.  Hence, I 
    40 strongly recommend you install WpdPack under the Cygwin root. 
     41strongly recommend you install it under the Cygwin root as /WpdPack. 
     42 
     43Note 2: 
     44There's a big problem with the Cygwin Guile package which breaks 
     45GNU Autogen which tcpreplay depends on when building from Subversion.  
     46 
     47What this means is that to build from Subversion you must do the following: 
     48- Download GNU Guile from http://www.gnu.org/software/guile/guile.html 
     49 
     50- Extract the tarball and do the following: 
     51libtoolize --copy --force 
     52./configure 
     53make 
     54make install 
     55 
     56This will install guile in /usr/local. 
     57 
     58The other problem is that guile-config returns the linker flags in the wrong  
     59order.  To fix this, rename /usr/local/bin/guile-config to  
     60/usr/local/bin/guile-config.original and create a new shell script in it's 
     61place: 
     62 
     63---- BEGIN SHELL SCRIPT ---- 
     64#!/bin/bash 
     65# Replacement /usr/local/bin/guile-config script 
     66if test -z "$1" ; then 
     67       guile-config.original 
     68elif test "$1" == "link"; then 
     69       echo "-L/usr/local/lib -lguile -lltdl -lgmp -lcrypt -lm -lltdl" 
     70else 
     71       guile-config.original $1 
     72fi 
     73---- END SHELL SCRIPT ---- 
     74 
    4175******************************* IMPORTANT ****************************** 
    4276 
     
    4680- Enter into the Cygwin environment by clicking on the Cygwin icon 
    4781 
    48 - If you checked out the code from SVN, run the autogen.sh bootstrapper: 
     82- If you checked out the code from SVN, see Note 2 above and then run  
     83  the autogen.sh bootstrapper: 
    4984        ./autogen.sh 
    5085 
    51     NOTE: I have a lot of problems building tcpreplay from SVN.  There's some 
    52     weird issue with Autogen and files which creates phantom files on the file 
    53     system and creates all kinds of problems.  Hence, I *HIGHLY* recommend you 
    54     grab a release tarball from the download page. 
    55  
    5686- Configure tcpreplay: 
    57         ./configure --with-libpcap=<path to winpcap> --enable-debug 
    58          
    59         Note: The winpcap developer pack needs to be accessible from the Cygwin  
    60         environment.  On my system, it's called /WpdPack, but due to how cygwin 
    61         works, I have to use all lowercase: --with-libpcap=/wpdpack 
     87        ./configure --enable-debug 
    6288 
    6389- Build tcpreplay:       
     
    6894         
    6995- Try it out! 
     96 
     97 
     98 
     99 
  • branches/3.3/src/common/sendpacket.c

    r2015 r2024  
    7373/* Allow users to force the injection method, default is linux PF_PACKET */ 
    7474#define INJECT_METHOD "PF_PACKET send()" 
     75 
    7576#ifdef FORCE_INJECT_LIBNET 
     77#undef HAVE_PF_PACKET 
    7678#undef HAVE_PCAP_INJECT 
    7779#undef HAVE_PCAP_SENDPACKET 
    7880#undef HAVE_BPF 
     81#undef INJECT_METHOD 
    7982#define INJECT_METHOD "libnet send()" 
    80 #elif defined FORCE_INJECT_BPF 
     83#endif 
     84 
     85#ifdef FORCE_INJECT_BPF 
    8186#undef HAVE_LIBNET 
    8287#undef HAVE_PCAP_INJECT 
    8388#undef HAVE_PCAP_SENDPACKET 
     89#undef HAVE_PF_PACKET 
     90#undef INJECT_METHOD 
    8491#define INJECT_METHOD "bpf send()" 
    85 #elif defined FORCE_INJECT_PCAP_INJECT 
     92#endif 
     93 
     94#ifdef FORCE_INJECT_PCAP_INJECT 
    8695#undef HAVE_LIBNET 
    8796#undef HAVE_PCAP_SENDPACKET 
    8897#undef HAVE_BPF 
     98#undef HAVE_PF_PACKET 
     99#undef INJECT_METHOD 
    89100#define INJECT_METHOD "pcap_inject()" 
    90 #elif defined FORCE_INJECT_PCAP_SENDPACKET 
     101#endif 
     102 
     103#ifdef FORCE_INJECT_PCAP_SENDPACKET 
    91104#undef HAVE_LIBNET 
    92105#undef HAVE_PCAP_INJECT 
    93106#undef HAVE_BPF 
     107#undef HAVE_PF_PACKET 
     108#undef INJECT_METHOD 
    94109#define INJECT_METHOD "pcap_sendpacket()" 
    95110#endif 
     
    606621    } 
    607622 
     623#if 0 /* why is this check necessary??? */ 
    608624    /* make sure it's ethernet */ 
    609625    switch (ifr.ifr_hwaddr.sa_family) { 
     
    616632            return NULL; 
    617633    } 
    618    
     634#endif 
     635 
    619636#ifdef SO_BROADCAST 
    620637    /*