Traceroute for Solaris 2.3

Traceroute for Solaris 2.3

Post by Clay Irvi » Thu, 14 Jul 1994 00:16:02



Anyone know where to snarf a copy of traceroute for Solaris 2.3?...

--
Clay Irving

 
 
 

Traceroute for Solaris 2.3

Post by Hal Pomera » Thu, 14 Jul 1994 00:30:59



> Anyone know where to snarf a copy of traceroute for Solaris 2.3?...

I just did the port yesterday morning.  Apply the diff given below to
traceroute.c.  Also add "-DSYSV" to CFLAGS and "-lsocket -lnsl" to LIBS
in the Makefile.

*** traceroute.c-dist   Mon Jul 11 11:26:32 1994
--- traceroute.c        Tue Jul 12 08:27:32 1994
***************
*** 191,197 ****
--- 191,201 ----

  #include <stdio.h>
  #include <errno.h>
+ #ifdef SYSV
+ #include <string.h>
+ #else
  #include <strings.h>
+ #endif
  #include <sys/time.h>

  #include <sys/param.h>
***************
*** 208,213 ****
--- 212,223 ----
  #include <netdb.h>
  #include <ctype.h>

+ #ifdef SYSV
+ #define index                strchr
+ #define bcopy(src,dst,len)     memcpy(dst,src,len)
+ #define bzero(src,len)         memset(src,0,len)
+ #endif
+
  #define       MAXPACKET       65535   /* max ip packet size */
  #ifndef MAXHOSTNAMELEN
  #define MAXHOSTNAMELEN        64
***************
*** 394,400 ****
--- 404,414 ----
                Printf(usage);
                exit(1);
        }
+ #ifdef SYSV
+       setbuf(stdout, (char *)NULL);
+ #else
        setlinebuf (stdout);
+ #endif

        (void) bzero((char *)&whereto, sizeof(struct sockaddr));
        to->sin_family = AF_INET;

--
==============================================================================

  Senior System Admin    "All I can say is that my life is pretty plain.
 TRW Financial Systems   I like watchin' the puddles gather rain." Blind Melon