]> git.pld-linux.org Git - packages/snort.git/blob - snort-libnet1.patch
- up to 2.6.1.3
[packages/snort.git] / snort-libnet1.patch
1 diff -NurpP --minimal snort-2.6.1.3.a/configure.in snort-2.6.1.3.b/configure.in
2 --- snort-2.6.1.3.a/configure.in        2007-03-09 10:08:24.000000000 +0100
3 +++ snort-2.6.1.3.b/configure.in        2007-03-09 10:39:29.000000000 +0100
4 @@ -797,21 +797,21 @@ if test "$enable_inline" != "no"; then
5          if test -n "$with_libnet_includes" -a "$with_libnet_includes" != "no"; then
6              libnet_dir="${with_libnet_includes}"
7           else
8 -            libnet_dir="/usr/include /usr/local/include /sw/include"
9 +            libnet_dir="/usr/include /usr/local/include /sw/include /usr/include/libnet1"
10          fi
11 -        AC_MSG_CHECKING("for libnet.h version 1.0.x")
12 +        AC_MSG_CHECKING("for libnet1.h version 1.0.x")
13          for i in $libnet_dir; do
14 -            if test -r $i/libnet.h; then
15 +            if test -r $i/libnet1.h; then
16                  LIBNET_INC_DIR=$i
17              fi
18          done
19  
20          if test "$LIBNET_INC_DIR" != ""; then
21 -            if eval "grep LIBNET_VERSION $LIBNET_INC_DIR/libnet.h | grep -v 1.0 >/dev/null"; then
22 -                FAIL_MESSAGE("libnet 1.0.x (libnet.h)", $LIBNET_INC_DIR)
23 +            if eval "grep LIBNET_VERSION $LIBNET_INC_DIR/libnet1.h | grep -v 1.0 >/dev/null"; then
24 +                FAIL_MESSAGE("libnet 1.0.x (libnet1.h)", $LIBNET_INC_DIR)
25              fi
26 -            CFLAGS="${CFLAGS} `libnet-config --defines` `libnet-config --cflags`"
27 -            LIBS="${LIBS} `libnet-config --libs`"
28 +            CFLAGS="${CFLAGS} `libnet1-config --defines` `libnet1-config --cflags`"
29 +            LIBS="${LIBS} `libnet1-config --libs`"
30              CPPFLAGS="${CPPFLAGS} -I${LIBNET_INC_DIR}"
31              AC_MSG_RESULT($i)
32          else
33 @@ -828,7 +828,7 @@ AC_ARG_ENABLE(inline-init-failopen,
34  
35  AC_ARG_ENABLE(flexresp,
36  [  --enable-flexresp        Flexible Responses on hostile connection attempts],
37 -[ CPPFLAGS="${CPPFLAGS} -DENABLE_RESPONSE `libnet-config --defines --cflags`" LDFLAGS="${LDFLAGS} `libnet-config --libs`"],)
38 +[ CPPFLAGS="${CPPFLAGS} -DENABLE_RESPONSE `libnet1-config --defines --cflags`" LDFLAGS="${LDFLAGS} `libnet1-config --libs`"],)
39                  
40  
41  if test "$enable_flexresp" != "no" -a "$enable_flexresp" = "yes"; then
42 @@ -838,13 +838,13 @@ if test "$enable_flexresp" != "no" -a "$
43      exit
44    fi
45  
46 -  if test `libnet-config --cflags | wc -c` = "1"; then
47 +  if test `libnet1-config --cflags | wc -c` = "1"; then
48      CPPFLAGS="${CPPFLAGS} -I/usr/local/include -I/sw/include"
49      LIBNET_CONFIG_BROKEN_CFLAGS=yes
50    fi
51  
52 -  if test `libnet-config --libs | wc -c` = "1"; then
53 -    AC_MSG_WARN(libnet-config --libs is broken on your system.  If you)
54 +  if test `libnet1-config --libs | wc -c` = "1"; then
55 +    AC_MSG_WARN(libnet1-config --libs is broken on your system.  If you)
56      AC_MSG_WARN(are using a precompiled package please notify the) 
57      AC_MSG_WARN(maintainer.)
58      LDFLAGS="${LDFLAGS} -L/usr/local/lib -L/sw/lib"
59 @@ -852,7 +852,7 @@ if test "$enable_flexresp" != "no" -a "$
60    fi
61  
62    LNET=""
63 -  AC_CHECK_HEADERS(libnet.h,, LNET="no")
64 +  AC_CHECK_HEADERS(libnet1.h,, LNET="no")
65    if test "$LNET" = "no"; then
66      echo
67      echo "   ERROR!  Libnet header not found, go get it from"
68 @@ -870,33 +870,33 @@ if test "$enable_flexresp" != "no" -a "$
69        libnet_dir="/usr/include /usr/local/include /sw/include"
70      fi
71    else
72 -    libnet_dir=`libnet-config --cflags | cut -dI -f2`
73 +    libnet_dir=`libnet1-config --cflags | cut -dI -f2`
74    fi
75  
76    LIBNET_INC_DIR=""
77    for i in $libnet_dir; do
78 -    if test -r $i/libnet.h; then
79 +    if test -r $i/libnet1.h; then
80        LIBNET_INC_DIR=$i
81      fi
82    done
83  
84    if test "$LIBNET_INC_DIR" != ""; then
85 -    if eval "grep LIBNET_VERSION $LIBNET_INC_DIR/libnet.h | grep -v 1.0.2a >/dev/null"; then
86 +    if eval "grep LIBNET_VERSION $LIBNET_INC_DIR/libnet1.h | grep -v 1.0.2a >/dev/null"; then
87        AC_MSG_RESULT(no)
88        echo
89        echo "   ERROR!  Snort with --enable-flexresp will *only* work with"
90        echo "   libnet version 1.0.2a, go get it from"
91        echo "   http://www.packetfactory.net/projects/libnet/"
92 -      FAIL_MESSAGE("libnet 1.0.2a (libnet.h)", $LIBNET_INC_DIR)
93 +      FAIL_MESSAGE("libnet 1.0.2a (libnet1.h)", $LIBNET_INC_DIR)
94      fi
95      AC_MSG_RESULT(yes)
96    else
97      AC_MSG_RESULT(no)
98 -    FAIL_MESSAGE("libnet 1.0.2a (libnet.h)", $libnet_dir)
99 +    FAIL_MESSAGE("libnet 1.0.2a (libnet1.h)", $libnet_dir)
100    fi
101  
102    LNET=""
103 -  AC_CHECK_LIB(net, libnet_build_ip,, LNET="no")
104 +  AC_CHECK_LIB(net1, libnet_build_ip,, LNET="no")
105    if test "$LNET" = "no"; then
106      echo
107      echo "   ERROR!  Libnet library not found, go get it from"
108 @@ -942,7 +942,7 @@ fi
109  
110  AC_ARG_ENABLE(react,
111  [  --enable-react           Intercept and terminate offending HTTP accesses],
112 -[ CPPFLAGS="${CPPFLAGS} -DENABLE_REACT `libnet-config --defines --cflags`" LDFLAGS="${LDFLAGS} `libnet-config --libs`"],)
113 +[ CPPFLAGS="${CPPFLAGS} -DENABLE_REACT `libnet1-config --defines --cflags`" LDFLAGS="${LDFLAGS} `libnet1-config --libs`"],)
114  
115  
116  if test "$enable_react" != "no" -a "$enable_react" = "yes"; then
117 @@ -953,13 +953,13 @@ if test "$enable_react" != "no" -a "$ena
118      exit
119    fi
120  
121 -  if test `libnet-config --cflags | wc -c` = "1"; then
122 +  if test `libnet1-config --cflags | wc -c` = "1"; then
123      CPPFLAGS="${CPPFLAGS} -I/usr/local/include -I/sw/include"
124      LIBNET_CONFIG_BROKEN_CFLAGS=yes
125    fi
126  
127 -  if test `libnet-config --libs | wc -c` = "1"; then
128 -    AC_MSG_WARN(libnet-config --libs is broken on your system.  If you)
129 +  if test `libnet1-config --libs | wc -c` = "1"; then
130 +    AC_MSG_WARN(libnet1-config --libs is broken on your system.  If you)
131      AC_MSG_WARN(are using a precompiled package please notify the)
132      AC_MSG_WARN(maintainer.)
133      LDFLAGS="${LDFLAGS} -L/usr/local/lib -L/sw/lib"
134 @@ -967,7 +967,7 @@ if test "$enable_react" != "no" -a "$ena
135    fi
136  
137    LNET=""
138 -  AC_CHECK_HEADERS(libnet.h,, LNET="no")
139 +  AC_CHECK_HEADERS(libnet1.h,, LNET="no")
140    if test "$LNET" = "no"; then
141      echo
142      echo "   ERROR!  Libnet header not found, go get it from"
143 @@ -985,33 +985,33 @@ if test "$enable_react" != "no" -a "$ena
144        libnet_dir="/usr/include /usr/local/include /sw/include"
145      fi
146    else
147 -    libnet_dir=`libnet-config --cflags | cut -dI -f2`
148 +    libnet_dir=`libnet1-config --cflags | cut -dI -f2`
149    fi
150  
151    LIBNET_INC_DIR=""
152    for i in $libnet_dir; do
153 -    if test -r $i/libnet.h; then
154 +    if test -r $i/libnet1.h; then
155        LIBNET_INC_DIR=$i
156      fi
157    done
158  
159    if test "$LIBNET_INC_DIR" != ""; then
160 -    if eval "grep LIBNET_VERSION $LIBNET_INC_DIR/libnet.h | grep -v 1.0.2a >/dev/null"; then
161 +    if eval "grep LIBNET_VERSION $LIBNET_INC_DIR/libnet1.h | grep -v 1.0.2a >/dev/null"; then
162        AC_MSG_RESULT(no)
163        echo
164        echo "   ERROR!  Snort with --enable-react will *only* work with"
165        echo "   libnet version 1.0.2a, go get it from"
166        echo "   http://www.packetfactory.net/projects/libnet/"
167 -      FAIL_MESSAGE("libnet 1.0.2a (libnet.h)", $LIBNET_INC_DIR)
168 +      FAIL_MESSAGE("libnet 1.0.2a (libnet1.h)", $LIBNET_INC_DIR)
169      fi
170      AC_MSG_RESULT(yes)
171    else
172      AC_MSG_RESULT(no)
173 -    FAIL_MESSAGE("libnet 1.0.2a (libnet.h)", $libnet_dir)
174 +    FAIL_MESSAGE("libnet 1.0.2a (libnet1.h)", $libnet_dir)
175    fi
176  
177    LNET=""
178 -  AC_CHECK_LIB(net, libnet_build_ip,, LNET="no")
179 +  AC_CHECK_LIB(net1, libnet_build_ip,, LNET="no")
180    if test "$LNET" = "no"; then
181      echo
182      echo "   ERROR!  Libnet library not found, go get it from"
183 diff -NurpP --minimal snort-2.6.1.3.a/src/detection-plugins/sp_react.c snort-2.6.1.3.b/src/detection-plugins/sp_react.c
184 --- snort-2.6.1.3.a/src/detection-plugins/sp_react.c    2007-03-09 10:08:23.000000000 +0100
185 +++ snort-2.6.1.3.b/src/detection-plugins/sp_react.c    2007-03-09 10:40:03.000000000 +0100
186 @@ -57,7 +57,7 @@
187  #include <stdlib.h>
188  #include <string.h>
189  #include <ctype.h>
190 -#include <libnet.h>
191 +#include <libnet1.h>
192  
193  #include "rules.h"
194  #include "decode.h"
195 diff -NurpP --minimal snort-2.6.1.3.a/src/detection-plugins/sp_respond.c snort-2.6.1.3.b/src/detection-plugins/sp_respond.c
196 --- snort-2.6.1.3.a/src/detection-plugins/sp_respond.c  2007-03-09 10:08:23.000000000 +0100
197 +++ snort-2.6.1.3.b/src/detection-plugins/sp_respond.c  2007-03-09 10:40:37.000000000 +0100
198 @@ -34,7 +34,7 @@
199  
200  
201  #if defined(ENABLE_RESPONSE) && !defined(ENABLE_RESPONSE2)
202 -#include <libnet.h>
203 +#include <libnet1.h>
204  
205  #include "decode.h"
206  #include "rules.h"
207 diff -NurpP --minimal snort-2.6.1.3.a/src/inline.c snort-2.6.1.3.b/src/inline.c
208 --- snort-2.6.1.3.a/src/inline.c        2007-03-09 10:08:23.000000000 +0100
209 +++ snort-2.6.1.3.b/src/inline.c        2007-03-09 10:41:19.000000000 +0100
210 @@ -20,7 +20,7 @@
211  #include <stdlib.h>
212  #include <string.h>
213  #include <pcap.h>
214 -#include <libnet.h>
215 +#include <libnet1.h>
216  
217  #include "decode.h"
218  #include "inline.h"
This page took 0.039548 seconds and 3 git commands to generate.