$NetBSD: patch-aa,v 1.3 1999/04/09 08:33:51 agc Exp $ Make this work on NetBSD and Solaris. --- Makefile.orig Fri Apr 9 09:25:00 1999 +++ Makefile Fri Apr 9 09:27:50 1999 @@ -23,7 +23,7 @@ DESTPATH = $(DESTROOT)/usr/local/rtty DESTBIN = $(DESTPATH)/bin -CC = cc +CC = gcc CDEBUG = -O -g # # use -U to undefine, -D to define @@ -35,15 +35,24 @@ # NO_SOCKADDR_LEN if your "struct sockaddr_in" lacks a sin_len field # NO_HSTRERROR if your C library has no hstrerror() function # -CDEFS = -DDEBUG -UWANT_TCPIP -UNEED_BITYPES_H -UNEED_STRDUP -UNEED_INET_ATON \ +CDEFS = -DDEBUG -UWANT_TCPIP -UNEED_BITYPES_H -UNEED_STRDUP \ -UNO_SOCKADDR_LEN -UNO_HSTRERROR # -CFLAGS = $(CDEBUG) $(CDEFS) -I/usr/local/include -LIBS = +CFLAGS+= $(CDEBUG) $(CDEFS) +LIBS = -lcrypt #(if WANT_TCPIP defined and this isn't in your libc) # -lresolv #(if the resolver needs it, which BIND>=4.9's will on BSD>=4.4 systems) # -l44bsd + +OPSYS!= uname -s + +.if ${OPSYS} == "NetBSD" +CDEFS+= -UNEED_INET_ATON +.elif ${OPSYS} == "SunOS" +LIBS+= -lsocket -lnsl +CDEFS+= -DNEED_INET_ATON +.endif BINARY = ttysrv rtty locbrok SCRIPT = Startup console startsrv agelogs agelog