--- conserver/Makefile.orig	Wed Feb 28 00:26:07 2001
+++ conserver/Makefile	Wed Feb 28 00:27:47 2001
@@ -7,8 +7,8 @@
 # (1) change ETC below to where you would like the console server installed
 # I would not change the name, you have to much with the docs then...
 PROG=	conserver
-ETC=	${DESTDIR}/usr/local/etc
-DOC=	${DESTDIR}/usr/local/man
+ETC=	${DESTDIR}/usr/local/sbin
+DOC=	${DESTDIR}/usr/local/man/man8
 
 # if we have to PUCC ptyd daemon we can use it to get ptys, else use fallback.o
 # and change the CDEFS line below to =0
@@ -23,9 +23,9 @@
 P=
 
 INCLUDE=
-DEBUG=-O
-CDEFS=  -DSUN5 -DHAVE_PTYD=0 -DDO_VIRTUAL=1
-CFLAGS= ${DEBUG} ${CDEFS} ${INCLUDE}
+DEBUG=
+CDEFS=  -DOPENBSD -DHAVE_PTYD=0 -DDO_VIRTUAL=1 -DPORT=782
+CFLAGS+= ${DEBUG} ${CDEFS} ${INCLUDE}
 
 HDR=	cons.h \
 	access.h client.h consent.h group.h main.h master.h \
@@ -41,7 +41,7 @@
 all: ${PROG}
 
 ${PROG}:$P ${OBJ}
-	${CC} -o $@ ${CFLAGS} ${OBJ} ${PUCCLIB} -lsocket -lnsl
+	${CC} -o $@ ${CFLAGS} ${OBJ} ${PUCCLIB}
 
 clean: FRC
 	rm -f Makefile.bak ${PROG} a.out *.o core errs lint.out tags
@@ -59,7 +59,8 @@
 	distrib -c ${ETC}/${PROG}
 
 install: all dirs FRC
-	install -c -s ${PROG} ${ETC}/${PROG}
+	install -c -s -o bin -g bin -m 555 ${PROG} ${ETC}/${PROG}
+	install -c -o bin -g bin -m 444 ${MAN} ${DOC}/conserver.8
 
 lint: ${HDR} ${SRC} FRC
 	lint -h ${CDEFS} ${INCLUDE} ${SRC}
