summaryrefslogtreecommitdiff
path: root/chat/phone/patches
diff options
context:
space:
mode:
authordholland <dholland@pkgsrc.org>2013-12-16 06:42:20 +0000
committerdholland <dholland@pkgsrc.org>2013-12-16 06:42:20 +0000
commit58788ca12e7a13de1facd4f82149799a8aed885a (patch)
tree4554ab3fbc5353eda1acdbbd2145c638f64f279b /chat/phone/patches
parentb6b4d7388b9567312bb1be9d265c87344041a319 (diff)
downloadpkgsrc-58788ca12e7a13de1facd4f82149799a8aed885a.tar.gz
Add chat/phone, which is like VMS phone, written by Jonathan C. Broome
in 1985 and fixed up by Christos "last week". (I've apparently been sitting on this package since 20130101, so it was a year ago...) XXX: this should probably grow an rc script for the master daemon, phoned.
Diffstat (limited to 'chat/phone/patches')
-rw-r--r--chat/phone/patches/patch-client_Makefile33
-rw-r--r--chat/phone/patches/patch-conv_Makefile28
-rw-r--r--chat/phone/patches/patch-master_Makefile46
-rw-r--r--chat/phone/patches/patch-master_utmp.c18
4 files changed, 125 insertions, 0 deletions
diff --git a/chat/phone/patches/patch-client_Makefile b/chat/phone/patches/patch-client_Makefile
new file mode 100644
index 00000000000..e02210f1721
--- /dev/null
+++ b/chat/phone/patches/patch-client_Makefile
@@ -0,0 +1,33 @@
+$NetBSD: patch-client_Makefile,v 1.1 2013/12/16 06:42:20 dholland Exp $
+
+Configure for pkgsrc.
+
+--- client/Makefile~ 2013-01-02 01:52:29.000000000 +0000
++++ client/Makefile
+@@ -25,7 +25,7 @@ LIBS = -lcurses -ltermlib #-lresolv
+
+ LPR = lpr
+ #RDEST = /usr/ucb/phone
+-RDEST = /usr/local/bin/phone
++RDEST = ${PREFIX}/bin/phone
+
+ HDRS = defs.h
+
+@@ -50,14 +50,14 @@ DEST = phone
+ all: ${DEST}
+
+ ${DEST}: ${OBJS}
+- /bin/rm -f ${DEST}
++ rm -f ${DEST}
+ ${CC} ${CFLAGS} -o ${DEST} ${OBJS} ${LIBS}
+
+ ${OBJS}: ${HDRS}
+
+ install: ${DEST}
+- /bin/rm -f ${RDEST}
+- cp ${DEST} ${RDEST}
++ rm -f ${RDEST}
++ ${BSD_INSTALL_PROGRAM} ${DEST} ${DESTDIR}${RDEST}
+
+ print: ${HDRS} ${SRCS}
+ pr -f ${HDRS} ${SRCS} | expand -4 | ${LPR}
diff --git a/chat/phone/patches/patch-conv_Makefile b/chat/phone/patches/patch-conv_Makefile
new file mode 100644
index 00000000000..05a2f74cc47
--- /dev/null
+++ b/chat/phone/patches/patch-conv_Makefile
@@ -0,0 +1,28 @@
+$NetBSD: patch-conv_Makefile,v 1.1 2013/12/16 06:42:20 dholland Exp $
+
+Configure for pkgsrc.
+
+--- conv/Makefile~ 2013-01-01 19:20:59.000000000 +0000
++++ conv/Makefile
+@@ -10,17 +10,17 @@ CFLAGS+= -std=gnu99 -Wall -Wstrict-prot
+ CFLAGS += -g
+ SRCS = convd.c
+ DEST = convd
+-RDEST = /usr/etc/convd
++RDEST = ${PREFIX}/libexec/convd
+
+ all: ${DEST}
+
+ ${DEST}: ${SRCS}
+- /bin/rm -f ${DEST}
++ rm -f ${DEST}
+ ${CC} ${CFLAGS} -o ${DEST} ${SRCS}
+
+ install: ${DEST}
+- /bin/rm -f ${RDEST}
+- cp ${DEST} ${RDEST}
++ rm -f ${RDEST}
++ ${BSD_INSTALL_PROGRAM} ${DEST} ${DESTDIR}${RDEST}
+
+ clean:
+ /bin/rm -f ${DEST} core *.o
diff --git a/chat/phone/patches/patch-master_Makefile b/chat/phone/patches/patch-master_Makefile
new file mode 100644
index 00000000000..88a8f96463d
--- /dev/null
+++ b/chat/phone/patches/patch-master_Makefile
@@ -0,0 +1,46 @@
+$NetBSD: patch-master_Makefile,v 1.1 2013/12/16 06:42:20 dholland Exp $
+
+Configure for pkgsrc.
+
+--- master/Makefile.orig 2013-01-01 23:59:38.000000000 +0000
++++ master/Makefile
+@@ -23,8 +23,10 @@
+ #OFLAG= -O
+ OFLAG= -g
+ #INETD= -DINETD
+-#FORK=-DFORK
+-CFLAGS = $(OFLAG) $(INETD) $(FORK) -DSERVICES -DDPATH=\"/u/christos/phone/conv/convd\"
++FORK=-DFORK
++# not -DSERVICES
++CFLAGS = $(OFLAG) $(INETD) $(FORK) -DDPATH=\"${PREFIX}/libexec/convd\"
++CFLAGS+= -DNO_WHO
+ CFLAGS+= -std=gnu99 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wno-sign-compare -Wno-traditional -Wa,--fatal-warnings -Wreturn-type -Wswitch -Wshadow -Wcast-qual -Wwrite-strings -Wextra -Wno-unused-parameter -Wno-sign-compare -Wold-style-definition -Wsign-compare -Wformat=2 -Wno-format-zero-length -Werror
+
+
+@@ -41,7 +43,7 @@ OBJS = child.o daemon.o dopage.o forward
+ reinvite.o sendit.o strsave.o utmp.o
+
+ DEST = phoned
+-RDEST = /usr/etc/in.phoned
++RDEST = ${PREFIX}/sbin/phoned
+ #RDEST = /etc/phoned
+
+
+@@ -51,14 +53,14 @@ RDEST = /usr/etc/in.phoned
+ all: ${DEST}
+
+ ${DEST}: ${OBJS}
+- /bin/rm -f ${DEST}
++ rm -f ${DEST}
+ ${CC} ${CFLAGS} -o ${DEST} ${OBJS}
+
+ ${OBJS}: ${HDRS}
+
+ install: ${DEST}
+- /bin/rm -f ${RDEST}
+- cp ${DEST} ${RDEST}
++ rm -f ${RDEST}
++ ${BSD_INSTALL_PROGRAM} ${DEST} ${DESTDIR}${RDEST}
+
+ clean:
+ /bin/rm -f ${DEST} core *.o
diff --git a/chat/phone/patches/patch-master_utmp.c b/chat/phone/patches/patch-master_utmp.c
new file mode 100644
index 00000000000..7da742a7b0a
--- /dev/null
+++ b/chat/phone/patches/patch-master_utmp.c
@@ -0,0 +1,18 @@
+$NetBSD: patch-master_utmp.c,v 1.1 2013/12/16 06:42:20 dholland Exp $
+
+Fix build failure when NO_WHO is defined.
+
+--- master/utmp.c~ 2013-01-02 02:07:17.000000000 +0000
++++ master/utmp.c
+@@ -69,9 +69,11 @@ findtty(const char *user, const char *tt
+ void
+ who(struct sockaddr_in *sin)
+ {
++#ifndef NO_WHO
+ struct utmpx *utmp;
+ int users = 0;
+ char *msg = NULL;
++#endif
+
+ #ifdef NO_WHO /* not allowed here ... */
+ sendit(misc, sin, "%c%c%cwho@%s: this site doesn't allow remote who.",