patches for clients.beta.44

Peter Van Epp vanepp at sfu.ca
Thu Aug 28 16:21:51 EDT 2003


	Below are the patches needed to get clients.beta.44 compiling on 
all of Mac OSX 10.2, FreeBSD 4.7 and 5.1, OpenBSD 3.2 and NetBSD 1.5 (some 
of which are probably old now :-)). NetBSD complains about DLT_SLIP_BSDOS
being redefined but its only a warning so I ignored it. MacOS 10 is unhappy
in ragrep:

gcc  -O -I. -I../include -I../common  -D_LARGEFILE_SOURCE=1 -D_FILE_OFFSET_BITS=64 -DHAVE_SYS_SOCKIO_H=1 -DHAVE_STRING_H=1 -DHAVE_FCNTL_H=1 -DHAVE_SYS_FILE_H=1 -DHAVE_SYSLOG_H=1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DSTDC_HEADERS=1   -o ../bin/ragrep  ragrep.o dfa.o kwset.o obstack.o search.o egrepmat.o regex.o  ../lib/argus_common.a ../lib/argus_parse.a ../lib/argus_client.a -lm 
ld: warning multiple definitions of symbol _regcomp
regex.o definition of _regcomp in section (__TEXT,__text)
/usr/lib/libm.dylib(regcomp.So) definition of _regcomp
ld: warning multiple definitions of symbol _regexec
regex.o definition of _regexec in section (__TEXT,__text)
/usr/lib/libm.dylib(regexec.So) definition of _regexec
ld: warning multiple definitions of symbol _regfree
regex.o definition of _regfree in section (__TEXT,__text)
/usr/lib/libm.dylib(regfree.So) definition of _regfree
 
	and it therefore may not work. The others seem clean at least as far
as compiling goes :-)

Peter Van Epp / Operations and Technical Support 
Simon Fraser University, Burnaby, B.C. Canada


*** include/compat.h.orig	Tue Aug 26 08:18:48 2003
--- include/compat.h	Tue Aug 26 08:25:03 2003
***************
*** 48,53 ****
--- 48,57 ----
  #include <strings.h>
  #endif
  
+ #if defined(__APPLE_CC__) || defined(__APPLE__)
+ #define __OpenBSD__ 1
+ #endif
+ 
  #if defined(HAVE_SOLARIS)
  #include <sys/byteorder.h>
  #include <limits.h>


*** common/gencode.c.orig	Tue Aug 26 09:53:29 2003
--- common/gencode.c	Wed Aug 27 14:27:32 2003
***************
*** 39,49 ****
   * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
   */
  
  
! #if defined(HAVE_SOLARIS) || (__FreeBSD__) || (__NetBSD__) || (__OpenBSD__)
  #include <sys/types.h>
  #include <sys/socket.h>
! #endif
  
  #include <unistd.h>
  
--- 39,50 ----
   * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
   */
  
+ #include <compat.h>
  
! #if defined(HAVE_SOLARIS) || (__FreeBSD__) || (__NetBSD__) || (__OpenBSD__) 
  #include <sys/types.h>
  #include <sys/socket.h>
! #endif 
  
  #include <unistd.h>
  
***************
*** 54,61 ****
  #include <setjmp.h>
  #include <stdarg.h>
  #include <stdlib.h>
- 
- #include <compat.h>
  
  #include <argus_client.h>
  #include <argus_filter.h>
--- 55,60 ----


*** clients/ranonymize.c.orig	Wed Aug 27 06:26:29 2003
--- clients/ranonymize.c	Wed Aug 27 06:33:02 2003
***************
*** 753,758 ****
--- 753,763 ----
  #endif
  }
  
+ #if defined (__OpenBSD__) 
+ #include <netinet/in_systm.h>
+ #include <netinet/ip.h>
+ #endif
+ 
  #include <netinet/ip_icmp.h>
  
  void


*** ratop/ratop.c.orig	Wed Aug 27 07:07:13 2003
--- ratop/ratop.c	Wed Aug 27 07:18:00 2003
***************
*** 37,43 ****
  
  #ifdef ARGUS_CURSES
  #include <curses.h>
! #if !defined(CYGWIN)
  #include <term.h>
  #else
  #include <termios.h>
--- 37,43 ----
  
  #ifdef ARGUS_CURSES
  #include <curses.h>
! #if !defined(CYGWIN) && !defined(__NetBSD__)
  #include <term.h>
  #else
  #include <termios.h>



More information about the argus mailing list