libgee: moved to github
[packages.git] / libs / libnids / patches / 002-configure.patch
1 --- a/configure
2 +++ b/configure
3 @@ -3640,7 +3640,7 @@ presetting ac_cv_c_bigendian=no (or yes)
4  esac
5  
6  
7 -CFLAGS="$CFLAGS -D_BSD_SOURCE"
8 +CFLAGS="$CFLAGS"
9  
10  for ac_func in gettimeofday
11  do
12 @@ -3917,17 +3917,21 @@ if test "${with_libpcap+set}" = set; the
13  echo "${ECHO_T}no" >&6
14       ;;
15    *)
16 -     echo "$as_me:$LINENO: result: $withval" >&5
17 -echo "${ECHO_T}$withval" >&6
18 +     echo "$ac_t""$withval" 1>&6
19       if test -f $withval/pcap.h -a -f $withval/libpcap.a; then
20          owd=`pwd`
21          if cd $withval; then withval=`pwd`; cd $owd; fi
22 -       PCAP_CFLAGS="-I$withval -I$withval/bpf"
23 +       PCAPINC="-I$withval -I$withval/bpf"
24         PCAPLIB="-L$withval -lpcap"
25 +     elif test -f $withval/include/pcap.h -a \
26 +              -f $withval/include/pcap-bpf.h -a \
27 +              -f $withval/lib/libpcap.a; then
28 +       owd=`pwd`
29 +       if cd $withval; then withval=`pwd`; cd $owd; fi
30 +       PCAPINC="-I$withval/include"
31 +       PCAPLIB="-L$withval/lib -lpcap"
32       else
33 -        { { echo "$as_me:$LINENO: error: pcap.h or libpcap.a not found in $withval" >&5
34 -echo "$as_me: error: pcap.h or libpcap.a not found in $withval" >&2;}
35 -   { (exit 1); exit 1; }; }
36 +        { echo "configure: error: pcap.h" 1>&2; exit 1; }
37       fi
38       ;;
39    esac
40 @@ -4399,10 +4403,10 @@ echo "${ECHO_T}no" >&6
41    *)
42       echo "$as_me:$LINENO: result: $withval" >&5
43  echo "${ECHO_T}$withval" >&6
44 -     if test -f $withval/include/libnet.h -a -f $withval/lib/libnet.a -a -f $withval/libnet-config ; then
45 +     if test -f $withval/include/libnet.h -a -f $withval/lib/libnet.a -a -f $withval/bin/libnet-config ; then
46          owd=`pwd`
47          if cd $withval; then withval=`pwd`; cd $owd; fi
48 -       LNET_CFLAGS="-I$withval/include `$withval/libnet-config --defines`"
49 +       LNET_CFLAGS="-I$withval/include `$withval/bin/libnet-config --defines`"
50         LNETLIB="-L$withval/lib -lnet"
51       elif test -f $withval/include/libnet.h -a -f $withval/src/libnet.a; then
52          owd=`pwd`
53 @@ -4684,7 +4688,7 @@ else
54    echo "$as_me: failed program was:" >&5
55  sed 's/^/| /' conftest.$ac_ext >&5
56  
57 -HAVE_BSD_UDPHDR=0
58 +HAVE_BSD_UDPHDR=1
59  fi
60  rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
61