Any input on the OpenSolaris issues I pointed out a few weeks back? Again, I have a fix that i can provide, but as I haven't contributed code to libpcap before, a quick primmer on what your process is would help me out.
Thanks, -Seb On Fri, 2009-01-23 at 13:47 -0500, Sebastien Roy wrote: > Hi Folks, > > I've downloaded libpcap 1.0.0 and am attempting to compile it on > OpenSolaris build 105. There are a number of problems in the > pcap-libdlpi.c file: > > gcc -O2 -I. -DHAVE_CONFIG_H -D_U_="__attribute__((unused))" -c > ./pcap-libdlpi.c > ./pcap-libdlpi.c: In function `pcap_activate_libdlpi': > ./pcap-libdlpi.c:116: error: `DLPI_SYSERR' undeclared (first use in this > function) > ./pcap-libdlpi.c:116: error: (Each undeclared identifier is reported only once > ./pcap-libdlpi.c:116: error: for each function it appears in.) > ./pcap-libdlpi.c:159: error: `promisc' undeclared (first use in this function) > ./pcap-libdlpi.c:182: error: `snaplen' undeclared (first use in this function) > ./pcap-libdlpi.c:212: error: `pcap_cleanup_libdlpi' undeclared (first use in > this function) > make: *** [pcap-libdlpi.o] Error 1 > > The first is that there is no such error as "DLPI_SYSERR". The error > should be "DL_SYSERR". The mysterious bit is that the patch that > initially integrated pcap-libdlpi.c had this right, but it was > subsequently changed (and the change was evidently not tested). > > The second is that there is no such global variable as "promisc". Use > of this global was evidently changed to pcap_t's opt.promisc in other > files, but was not fixed in this one. > > The third is the use of "snaplen". I'm not sure what happened here > (this code compiled in previous versions of libpcap). Perhaps this > should be changed to p->snapshot.(?) > > The fourth is that pcap_cleanup_libdlpi is being referenced before it's > declared. It needs a forward declaration. > > I have these issues fixed locally, and I can provide this fix to the > main repository. Let me know what you'd like me to do to submit the > fix, and I'll do it. > > On a related note, if anyone wishes to make changes to pcap-libdlpi.c > and doesn't have an OpenSolaris system to compile and test their changes > on, I'd be more than glad to help out with this. > > -Seb > - This is the tcpdump-workers list. Visit https://cod.sandelman.ca/ to unsubscribe.