Martin Michlmayr <[EMAIL PROTECTED]> (20/01/2008):
> retitle 456091 FTBFS with GCC 4.3: missing #includes
> thanks
> 
> I mentioned that GCC 4.3 converted a number of C++ warnings into
> errors.  This change has now been reverted after a lot of
> discussion.  I just compiled your package with the latest snapshot
> of GCC 4.3 to see if it compiles with 4.3, but there is another issue:
> 
> g++  -DVERSION_MAJOR=\"2007\" -DVERSION_MINOR=\"10\"
> -DVERSION_TINY=\"R1\" -DTIMESTAMP=\"`cat TIMESTAMP`\" -g -Wall -O2 -c
> util.cc -o util.o·
> In file included from util.cc:21:
> util.h:68: warning: 'typedef' was ignored in this declaration
> util.cc: In function 'int Hex2UChar(unsigned char*, unsigned char*)':
> util.cc:116: error: 'memset' was not declared in this scope
> make[1]: *** [util.o] Error 1

Here's a prospective patch, but then it fails on:
| gpsmap.cc:315: warning: ‘typedef’ was ignored in this declaration
| gpsmap.cc:2107: warning: ‘typedef’ was ignored in this declaration
| gpsmap.cc: In function ‘int main(int, char**)’:
| gpsmap.cc:3550: warning: ‘wt’ may be used uninitialized in this function
| --ldflags: unknown option
| g++ -Xlinker -rpath /usr/lib/wireshark -o gpsmap getopt.o util.o configfile.o 
expat.o manuf.o gpsmap_cache.o gpsmap_samples.o gpsmap.o -lstdc++ -lm -lz 
-lWand -lMagick -lpthread -lexpat -lgmp
| --ldflags: unknown option

Cheers,

-- 
Cyril Brulebois
--- a/kismet_wrapper.cc
+++ b/kismet_wrapper.cc
@@ -28,6 +28,8 @@
 
 #include "config.h"
 
+#include <cstring>
+
 /* Blob of globals since sighandler needs them */
 vector<string> postcli_err;
 pid_t srvpid = -1, clipid = -1;
--- a/ringbuf.cc
+++ b/ringbuf.cc
@@ -18,6 +18,8 @@
 
 #include "ringbuf.h"
 
+#include <cstring>
+
 RingBuffer::RingBuffer(int in_size) {
     ring_len = in_size;
     ring_data = new uint8_t[in_size];
--- a/util.cc
+++ b/util.cc
@@ -23,6 +23,8 @@
 #include <sys/stat.h>
 #include <fcntl.h>
 
+#include <cstring>
+
 // We need this to make uclibc happy since they don't even have rintf...
 #ifndef rintf
 #define rintf(x) (float) rint((double) (x))

Attachment: signature.asc
Description: Digital signature

Reply via email to