summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorhubertf <hubertf@pkgsrc.org>1999-11-26 22:12:36 +0000
committerhubertf <hubertf@pkgsrc.org>1999-11-26 22:12:36 +0000
commit4825e883ec62bf7c36ef774ed7dcf3963a8057c0 (patch)
tree83487d86e1858fda554a9a109f207dc0088907e3 /net
parent9e5d4ff0b95c207204cdaed951e3efde66abb205 (diff)
downloadpkgsrc-4825e883ec62bf7c36ef774ed7dcf3963a8057c0.tar.gz
Split patches and add code to print time in front of each line.
Needs to be switched on from .icbrc: oset printtime true. Bump version to 5.0.9pl1 for that.
Diffstat (limited to 'net')
-rw-r--r--net/icb/Makefile4
-rw-r--r--net/icb/files/patch-sum31
-rw-r--r--net/icb/patches/patch-aa75
-rw-r--r--net/icb/patches/patch-ab32
-rw-r--r--net/icb/patches/patch-ac24
-rw-r--r--net/icb/patches/patch-ad68
-rw-r--r--net/icb/patches/patch-ae36
-rw-r--r--net/icb/patches/patch-af36
-rw-r--r--net/icb/patches/patch-ag56
-rw-r--r--net/icb/patches/patch-ah23
-rw-r--r--net/icb/patches/patch-ai130
-rw-r--r--net/icb/patches/patch-aj82
-rw-r--r--net/icb/patches/patch-ak102
-rw-r--r--net/icb/patches/patch-al36
-rw-r--r--net/icb/patches/patch-am27
-rw-r--r--net/icb/patches/patch-an68
-rw-r--r--net/icb/patches/patch-ao18
-rw-r--r--net/icb/patches/patch-ap60
-rw-r--r--net/icb/patches/patch-aq35
19 files changed, 513 insertions, 430 deletions
diff --git a/net/icb/Makefile b/net/icb/Makefile
index 01474f51cf7..bdabffd7086 100644
--- a/net/icb/Makefile
+++ b/net/icb/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.8 1998/11/20 17:27:57 tsarna Exp $
+# $NetBSD: Makefile,v 1.9 1999/11/26 22:12:36 hubertf Exp $
#
-DISTNAME= icb-5.0.9
+DISTNAME= icb-5.0.9pl1
CATEGORIES= net
MASTER_SITES= ${MASTER_SITE_LOCAL}
diff --git a/net/icb/files/patch-sum b/net/icb/files/patch-sum
index 5c0a4b17dc1..6d87d7c6ba6 100644
--- a/net/icb/files/patch-sum
+++ b/net/icb/files/patch-sum
@@ -1,14 +1,19 @@
-$NetBSD: patch-sum,v 1.2 1999/09/29 00:42:16 christos Exp $
+$NetBSD: patch-sum,v 1.3 1999/11/26 22:12:37 hubertf Exp $
-MD5 (patch-aa) = b9dcffb6a36a88ac3b5d7bb845ad7a5f
-MD5 (patch-ab) = 4f6a92f5789bb02be69bb5f6fc695b05
-MD5 (patch-ac) = 8d798e3a29e9658ebf40ee60970af5d0
-MD5 (patch-ad) = ea43d5a7ec82d195b93c0e84854802f0
-MD5 (patch-ae) = 626968ef0a20556d3abed6805b057e34
-MD5 (patch-af) = 62a44cab31c04491fff23e2722c1a695
-MD5 (patch-ag) = efaee796958fde992c0dce0bb648d70c
-MD5 (patch-ah) = 2be74e86c4213068c8bdf6823637a1c0
-MD5 (patch-ai) = d4df0e819c6268376a1a695db4928cd4
-MD5 (patch-aj) = 277c5620504cebe99a4fdf145630e293
-MD5 (patch-ak) = 1e718dbb414eb13fc33063355f899c34
-MD5 (patch-al) = 2f3efc8f3959a60b82bb06331aaa4005
+MD5 (patch-aa) = 1dbe6280e8f26757116c633892b2ea76
+MD5 (patch-ab) = af1c56e0de45046d2f36c1b4b7558741
+MD5 (patch-ac) = 4ab936ec1ad42beb7ceed7372807747a
+MD5 (patch-ad) = dcfe2f67487ec52d26d8df8bd589609a
+MD5 (patch-ae) = ee233ed0ce26a3388d8a5011d356a6e6
+MD5 (patch-af) = 29d28cc0e6a97a3f7a372391beebc1d6
+MD5 (patch-ag) = c5982519155cd89c9c58b9dc4d0bffcf
+MD5 (patch-ah) = 236d9cb118b325ee23135259e7981ea8
+MD5 (patch-ai) = 61eebb483ef75f5d6b86212c0b60c048
+MD5 (patch-aj) = 35794c14dd5975ba7b91efdc25905d2a
+MD5 (patch-ak) = d60689a2090fbedd4d0092e561f3a6f9
+MD5 (patch-al) = c7bdb306490980e1a549f838dd3a0652
+MD5 (patch-am) = 96ab9521ecc69d670c445e0acf724279
+MD5 (patch-an) = b618da755e0a9383a7c5429a062d12e5
+MD5 (patch-ao) = 1b382d84b41e37130a49300e21945789
+MD5 (patch-ap) = ddd5c1ff9deb3e7c38264675305b0098
+MD5 (patch-aq) = ab312e8e310b08633a504b6c19aa2289
diff --git a/net/icb/patches/patch-aa b/net/icb/patches/patch-aa
index b5e8b251449..88be43cebc0 100644
--- a/net/icb/patches/patch-aa
+++ b/net/icb/patches/patch-aa
@@ -1,57 +1,22 @@
---- tcl/tclCmdAH.c.orig Fri Feb 24 22:19:53 1995
-+++ tcl/tclCmdAH.c Tue Jun 1 10:55:15 1999
-@@ -38,9 +38,22 @@ static char rcsid[] = "$Header: /home/ag
- #include <sys/wait.h>
- #include "tclInt.h"
+$NetBSD: patch-aa,v 1.7 1999/11/26 22:12:37 hubertf Exp $
+
+diff -x *.orig -urN ./icb/c_log.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/c_log.c
+--- ./icb/c_log.c Fri Feb 24 22:20:18 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/c_log.c Fri Nov 26 22:56:29 1999
+@@ -6,6 +6,7 @@
+ #include "icb.h"
+ #include "externs.h"
+ #include <time.h>
++#include <errno.h>
-+#ifdef __NetBSD__
-+#define unix
-+#endif
-+
-+#if (defined(__unix__) || defined(unix)) && !defined(USG)
-+#include <sys/param.h>
-+#include <unistd.h>
-+#endif
-+
- extern int errno;
-+#if !(defined(BSD) && BSD >= 199306)
- extern long lseek();
-+#endif
-+#ifndef BSD4_4
- extern char *mktemp();
-+#endif
-
- /*
- *----------------------------------------------------------------------
-@@ -430,7 +443,7 @@ Tcl_ExecCmd(dummy, interp, argc, argv)
- int pid = -1; /* -1 means child process doesn't
- * exist (yet). Non-zero gives its
- * id (0 only in child). */
-- union wait status;
-+ int status;
- char *cmdName, *execName;
+ FILE *logfp = NULL;
- /*
-@@ -501,8 +514,13 @@ Tcl_ExecCmd(dummy, interp, argc, argv)
- } else {
- char tmp[sizeof(TMP_FILE_NAME) + 1];
- strcpy(tmp, TMP_FILE_NAME);
-+#ifdef BSD4_4
-+ mkstemp(tmp);
-+ stdIn[0] = mkstemp(tmp);
-+#else
- mktemp(tmp);
- stdIn[0] = open(tmp, O_RDWR|O_CREAT, 0);
-+#endif
- if (stdIn[0] < 0) {
- sprintf(interp->result,
- "couldn't create input file for \"%.50s\" command: %.50s",
-@@ -642,7 +660,7 @@ Tcl_ExecCmd(dummy, interp, argc, argv)
- sprintf(interp->result, "command terminated abnormally");
- result = TCL_ERROR;
- }
-- result = status.w_retcode;
-+ result = WEXITSTATUS(status);
- }
- if (stdIn[0] != -1) {
- close(stdIn[0]);
+@@ -45,8 +46,6 @@
+ time_t time();
+ struct tm *t, *localtime();
+ time_t clock;
+- extern int errno, sys_nerr;
+- extern char *sys_errlist[];
+
+ /* determine pathname to use */
+ if (path == NULL || *path == '\0')
diff --git a/net/icb/patches/patch-ab b/net/icb/patches/patch-ab
index 5873f246da2..4ac73ed09ca 100644
--- a/net/icb/patches/patch-ab
+++ b/net/icb/patches/patch-ab
@@ -1,20 +1,14 @@
-$NetBSD: patch-ab,v 1.2 1998/08/07 11:10:41 agc Exp $
+$NetBSD: patch-ab,v 1.3 1999/11/26 22:12:37 hubertf Exp $
---- icb/strings.c Wed Feb 10 12:10:41 1993
-+++ icb/strings.c Wed Mar 18 13:48:15 1998
-@@ -337,6 +337,7 @@
- /* cat multiple strings into one */
- /* call with strscat(dest, src, src, ...) */
-
-+#if 0
- char *
- strscat(va_alist)
- va_dcl
-@@ -361,6 +362,7 @@
- *dest = '\0';
- return(dest);
- }
-+#endif
-
- char *basename(path)
- char *path;
+diff -x *.orig -urN ./icb/c_shell.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/c_shell.c
+--- ./icb/c_shell.c Fri Feb 24 22:20:19 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/c_shell.c Fri Nov 26 22:56:29 1999
+@@ -14,7 +14,7 @@
+ static char *usage = "usage: c_shell [command]";
+ int w, pid;
+ int shellout = 0;
+- union wait status;
++ int status;
+ char *shell, *getenv();
+
+ /* disallow use if restricted mode set */
diff --git a/net/icb/patches/patch-ac b/net/icb/patches/patch-ac
index bd274ca70a6..13471208990 100644
--- a/net/icb/patches/patch-ac
+++ b/net/icb/patches/patch-ac
@@ -1,13 +1,13 @@
-$NetBSD: patch-ac,v 1.2 1998/08/07 11:10:41 agc Exp $
+$NetBSD: patch-ac,v 1.3 1999/11/26 22:12:37 hubertf Exp $
---- icb/protos.h-orig Fri Feb 24 22:20:25 1995
-+++ icb/protos.h Wed Apr 15 12:07:50 1998
-@@ -64,7 +64,7 @@
- int inserttab(void);
- int ishushed(char *nick);
- int lcaseit(char *s);
--#ifdef linux
-+#if defined(linux) || (defined(BSD) && BSD >= 199306)
- int linebuffer(FILE *fp);
- #else
- int linebuffer(struct _iobuf *fp);
+diff -x *.orig -urN ./icb/globals.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/globals.c
+--- ./icb/globals.c Fri Feb 24 22:20:22 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/globals.c Fri Nov 26 22:56:30 1999
+@@ -59,6 +59,7 @@
+ 1, /* beeps */
+ "vi", /* editmode */
+ 0, /* tabreply */
++ 0, /* printtime */
+ 1, /* cute */
+ 0, /* autodel */
+ "", /* personalto */
diff --git a/net/icb/patches/patch-ad b/net/icb/patches/patch-ad
index 35274c18bd4..b897555d26a 100644
--- a/net/icb/patches/patch-ad
+++ b/net/icb/patches/patch-ad
@@ -1,51 +1,17 @@
---- icb/serverlist.c.orig Fri Feb 24 22:20:29 1995
-+++ icb/serverlist.c Tue Jun 1 10:43:14 1999
-@@ -1,4 +1,6 @@
- #include <stdio.h>
-+#include <stdlib.h>
-+#include <pwd.h>
- #include <sys/types.h>
- #include <sys/stat.h>
- #include "icb.h"
-@@ -14,15 +16,14 @@ static FILE *serverfile = NULL;
- FILE *openserverfile()
- {
- struct stat statbuf;
-- char *personalsl;
-- char command[256];
-- char pwd[256];
-+ char *personalsl, *home;
-+ char pwd[MAXPATHLEN+1];
- FILE *ret;
-
- #ifdef sgi
- #undef SYSV
- #endif
--#ifndef SYSV
-+#if !defined(SYSV) && !(defined(BSD) && BSD >= 199306)
- getwd(pwd);
- #else /* SYSV */
- getcwd(pwd, MAXPATHLEN+1);
-@@ -30,11 +31,20 @@ FILE *openserverfile()
- #ifdef sgi
- #define SYSV
- #endif
-- chdir(getenv("HOME"));
-+ if ((home = getenv("HOME")) == NULL) {
-+ struct passwd *pw;
-+ if ((pw = getpwuid(getuid())) == NULL)
-+ home = ".";
-+ home = pw->pw_dir;
-+ }
-+ chdir(home);
- if (!stat(PERSONALSL,&statbuf))
- {
-- sprintf(command,"/bin/cat %s %s\n", PERSONALSL, SERVERLIST);
-+ char *command = malloc(strlen("/bin/cat \n") +
-+ strlen(PERSONALSL) + strlen(SERVERLIST) + 1);
-+ sprintf(command, "/bin/cat %s %s\n", PERSONALSL, SERVERLIST);
- ret= popen(command,"r");
-+ free(command);
- }
- else
- ret= fopen(SERVERLIST,"r");
+$NetBSD: patch-ad,v 1.4 1999/11/26 22:12:37 hubertf Exp $
+
+diff -x *.orig -urN ./icb/helpdata.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/helpdata.c
+--- ./icb/helpdata.c Fri Feb 24 22:20:23 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/helpdata.c Fri Nov 26 22:56:30 1999
+@@ -600,6 +600,11 @@
+ " waiting for your screen, this gives you a chance to see the output",
+ " of your command.",
+ "",
++"printtime (boolean) default: false",
++"",
++" Print the current time in front of every line sent to the display",
++" and log file.",
++"",
+ "restricted (boolean) default: false",
+ "",
+ " Restricted shuts off the ability to run subshell commands or to",
diff --git a/net/icb/patches/patch-ae b/net/icb/patches/patch-ae
index c5d0af6d21c..4a0d1ef5c67 100644
--- a/net/icb/patches/patch-ae
+++ b/net/icb/patches/patch-ae
@@ -1,25 +1,13 @@
-$NetBSD: patch-ae,v 1.2 1998/11/12 23:40:20 frueauf Exp $
+$NetBSD: patch-ae,v 1.3 1999/11/26 22:12:37 hubertf Exp $
-*** icb/unix.c.orig Fri Feb 24 16:20:31 1995
---- icb/unix.c Thu Sep 3 10:28:33 1998
-***************
-*** 49,56 ****
- if (((loginid = getlogin()) == NULL) || *loginid == '\0')
- if ((pw = getpwuid(getuid())) == NULL)
- loginid = NULL;
-! else
-! loginid = pw->pw_name;
- return(loginid);
- }
-
---- 49,58 ----
- if (((loginid = getlogin()) == NULL) || *loginid == '\0')
- if ((pw = getpwuid(getuid())) == NULL)
- loginid = NULL;
-! else {
-! loginid = malloc(strlen(pw->pw_name) + 1);
-! strcpy(loginid, pw->pw_name);
-! }
- return(loginid);
- }
-
+diff -x *.orig -urN ./icb/icb.h /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/icb.h
+--- ./icb/icb.h Fri Feb 24 22:20:23 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/icb.h Fri Nov 26 22:56:30 1999
+@@ -38,6 +38,7 @@
+ int beeps; /* whether beeps are audible */
+ char *editmode; /* input editing mode */
+ int tabreply; /* should replies go into the tab history? */
++ int printtime; /* print timestamp in front of every msg? */
+ int cute; /* cute messages when a blank line is entered */
+ int autodel; /* automatically delete nicks from the tab
+ history that produce a "not logged on" error */
diff --git a/net/icb/patches/patch-af b/net/icb/patches/patch-af
index b37912cc585..ceba9beaa9f 100644
--- a/net/icb/patches/patch-af
+++ b/net/icb/patches/patch-af
@@ -1,25 +1,13 @@
-$NetBSD: patch-af,v 1.1 1999/02/10 22:31:56 jwise Exp $
+$NetBSD: patch-af,v 1.2 1999/11/26 22:12:37 hubertf Exp $
-*** icb/c_log.c.orig Fri Feb 24 16:20:18 1995
---- icb/c_log.c Wed Feb 10 17:06:17 1999
-***************
-*** 6,11 ****
---- 6,12 ----
- #include "icb.h"
- #include "externs.h"
- #include <time.h>
-+ #include <errno.h>
-
- FILE *logfp = NULL;
-
-***************
-*** 45,52 ****
- time_t time();
- struct tm *t, *localtime();
- time_t clock;
-- extern int errno, sys_nerr;
-- extern char *sys_errlist[];
-
- /* determine pathname to use */
- if (path == NULL || *path == '\0')
---- 46,51 ----
+diff -x *.orig -urN ./icb/oset.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/oset.c
+--- ./icb/oset.c Fri Feb 24 22:20:24 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/oset.c Fri Nov 26 22:56:31 1999
+@@ -39,6 +39,7 @@
+ { "pagesize", V_INT, (char *)&gv.pagesize },
+ { "pauseonshell", V_BOOLEAN, (char *)&gv.pauseonshell },
+ { "personalto", V_STRING, (char *)&gv.personalto },
++ { "printtime", V_BOOLEAN, (char *)&gv.printtime },
+ { "restricted", V_BOOLEAN, (char *)&gv.restricted },
+ { "tabreply", V_BOOLEAN, (char *)&gv.tabreply },
+ { "timedisplay", V_STRING, (char *)&gv.timedisplay },
diff --git a/net/icb/patches/patch-ag b/net/icb/patches/patch-ag
index 04ee5ae611a..9ed3e0fee1f 100644
--- a/net/icb/patches/patch-ag
+++ b/net/icb/patches/patch-ag
@@ -1,11 +1,45 @@
---- icb/c_shell.c.orig Tue Jun 1 10:38:15 1999
-+++ icb/c_shell.c Tue Jun 1 10:38:47 1999
-@@ -14,7 +14,7 @@ TARGDEFS
- static char *usage = "usage: c_shell [command]";
- int w, pid;
- int shellout = 0;
-- union wait status;
-+ int status;
- char *shell, *getenv();
-
- /* disallow use if restricted mode set */
+$NetBSD: patch-ag,v 1.2 1999/11/26 22:12:37 hubertf Exp $
+
+diff -x *.orig -urN ./icb/print.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/print.c
+--- ./icb/print.c Fri Feb 24 22:20:25 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/print.c Fri Nov 26 22:56:31 1999
+@@ -5,6 +5,7 @@
+
+ #include "icb.h"
+ #include "externs.h"
++#include <time.h>
+
+ extern FILE *logfp;
+
+@@ -17,12 +18,22 @@
+ char printbuf[1024];
+ char *p = printbuf;
+ char *t = s;
++ struct tm *tm, *localtime();
++ char timestamp[9];
+
+ if (continued) {
+ linenumber = 0;
+ continued = 0;
+ }
+
++ /* If requested, prepare timestamp */
++ if (gv.printtime) {
++ gettime();
++ tm = localtime(&curtime);
++ snprintf(timestamp, sizeof(timestamp), "[%02d:%02d]",
++ tm->tm_hour, tm->tm_min);
++ }
++
+ if (flags & PL_SCR) {
+ /* if paging in effect, do paging */
+ if (gv.pagesize && (++linenumber >= gv.pagesize)) {
+@@ -35,6 +46,8 @@
+ *p++ = *t++;
+ *p++ = '\r';
+ *p++ = '\n';
++ if (gv.printtime)
++ write(1, timestamp, 7);
+ write(1, printbuf, p - printbuf);
+ }
+
diff --git a/net/icb/patches/patch-ah b/net/icb/patches/patch-ah
index 0e3036fb9a6..ebccc60b478 100644
--- a/net/icb/patches/patch-ah
+++ b/net/icb/patches/patch-ah
@@ -1,11 +1,14 @@
---- murgil/getrname.c.orig Tue Jun 1 10:28:17 1999
-+++ murgil/getrname.c Tue Jun 1 10:34:27 1999
-@@ -14,7 +14,7 @@ int s; /* connected socket fd */
- {
- static char rname[24];
- struct hostent *host;
--#if defined(linux)
-+#if defined(linux) || defined(__NetBSD__)
- #define PEER_CAST (struct sockaddr *)
- #define HOST_CAST (char *)
+$NetBSD: patch-ah,v 1.2 1999/11/26 22:12:37 hubertf Exp $
+
+diff -x *.orig -urN ./icb/protos.h /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/protos.h
+--- ./icb/protos.h Fri Feb 24 22:20:25 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/protos.h Fri Nov 26 22:56:28 1999
+@@ -64,7 +64,7 @@
+ int inserttab(void);
+ int ishushed(char *nick);
+ int lcaseit(char *s);
+-#ifdef linux
++#if defined(linux) || (defined(BSD) && BSD >= 199306)
+ int linebuffer(FILE *fp);
#else
+ int linebuffer(struct _iobuf *fp);
diff --git a/net/icb/patches/patch-ai b/net/icb/patches/patch-ai
index 9c4cbf1fc55..914c877d999 100644
--- a/net/icb/patches/patch-ai
+++ b/net/icb/patches/patch-ai
@@ -1,78 +1,54 @@
-$NetBSD: patch-ai,v 1.1 1999/09/29 00:41:52 christos Exp $
+$NetBSD: patch-ai,v 1.2 1999/11/26 22:12:37 hubertf Exp $
-*** icb/serverlist.c.orig Tue Sep 28 19:14:47 1999
---- icb/serverlist.c Tue Sep 28 19:15:09 1999
-***************
-*** 23,29 ****
- #ifdef sgi
- #undef SYSV
- #endif
-! #if !defined(SYSV) && !(defined(BSD) && BSD >= 199306)
- getwd(pwd);
- #else /* SYSV */
- getcwd(pwd, MAXPATHLEN+1);
---- 23,29 ----
- #ifdef sgi
- #undef SYSV
- #endif
-! #if !defined(SYSV) && !(defined(BSD) && BSD >= 199306) && !defined(__linux__)
- getwd(pwd);
- #else /* SYSV */
- getcwd(pwd, MAXPATHLEN+1);
-*** icb/unix.c.orig Tue Sep 28 19:14:47 1999
---- icb/unix.c Tue Sep 28 19:15:42 1999
-***************
-*** 4,9 ****
---- 4,11 ----
- /* This file contains routines that are unix dependent. */
- /* Eventually, most unixisms should be moved here. */
-
-+ #include <sys/types.h>
-+ #include <sys/param.h>
- #include <stdio.h>
- #include "icb.h"
- #include "externs.h"
-***************
-*** 13,18 ****
---- 15,28 ----
- #undef stty
- #undef gtty
-
-+ #if defined(__linux__)
-+ #include <termios.h>
-+ #include <sys/ioctl.h>
-+ #define TTYSTRUCT termios
-+ #define stty(fd,buf) tcgetattr((fd), (buf))
-+ #define gtty(fd,buf) tcsetattr((fd), TCSANOW, (buf))
-+ #define SYSV
-+ #else
- #ifndef SYSV
-
- #ifdef linux
-***************
-*** 30,35 ****
---- 40,46 ----
- #define stty(fd,buf) ioctl((fd),TCSETA,(buf))
- #define gtty(fd,buf) ioctl((fd),TCGETA,(buf))
- #endif /* SYSV */
-+ #endif /* __linux__ */
-
- char *getlogin();
-
-***************
-*** 183,189 ****
-
- getwinsize()
- {
-! #ifndef NOWINSIZE
- struct winsize win;
-
- /* get tty settings */
---- 194,200 ----
-
- getwinsize()
- {
-! #ifdef TIOCGWINSZ
- struct winsize win;
-
- /* get tty settings */
+diff -x *.orig -urN ./icb/serverlist.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/serverlist.c
+--- ./icb/serverlist.c Fri Feb 24 22:20:29 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/serverlist.c Fri Nov 26 22:56:29 1999
+@@ -1,4 +1,6 @@
+ #include <stdio.h>
++#include <stdlib.h>
++#include <pwd.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include "icb.h"
+@@ -14,15 +16,14 @@
+ FILE *openserverfile()
+ {
+ struct stat statbuf;
+- char *personalsl;
+- char command[256];
+- char pwd[256];
++ char *personalsl, *home;
++ char pwd[MAXPATHLEN+1];
+ FILE *ret;
+
+ #ifdef sgi
+ #undef SYSV
+ #endif
+-#ifndef SYSV
++#if !defined(SYSV) && !(defined(BSD) && BSD >= 199306) && !defined(__linux__)
+ getwd(pwd);
+ #else /* SYSV */
+ getcwd(pwd, MAXPATHLEN+1);
+@@ -30,11 +31,20 @@
+ #ifdef sgi
+ #define SYSV
+ #endif
+- chdir(getenv("HOME"));
++ if ((home = getenv("HOME")) == NULL) {
++ struct passwd *pw;
++ if ((pw = getpwuid(getuid())) == NULL)
++ home = ".";
++ home = pw->pw_dir;
++ }
++ chdir(home);
+ if (!stat(PERSONALSL,&statbuf))
+ {
+- sprintf(command,"/bin/cat %s %s\n", PERSONALSL, SERVERLIST);
++ char *command = malloc(strlen("/bin/cat \n") +
++ strlen(PERSONALSL) + strlen(SERVERLIST) + 1);
++ sprintf(command, "/bin/cat %s %s\n", PERSONALSL, SERVERLIST);
+ ret= popen(command,"r");
++ free(command);
+ }
+ else
+ ret= fopen(SERVERLIST,"r");
diff --git a/net/icb/patches/patch-aj b/net/icb/patches/patch-aj
index a4c9f844be4..01bb127f0a0 100644
--- a/net/icb/patches/patch-aj
+++ b/net/icb/patches/patch-aj
@@ -1,65 +1,21 @@
---- readline/readline.c.orig Fri Feb 24 16:20:03 1995
-+++ readline/readline.c Tue Sep 28 19:10:59 1999
-@@ -48,7 +48,11 @@
- # include <unistd.h>
- #endif
-
-+#if !defined(__linux__)
- #define NEW_TTY_DRIVER
-+#else
-+#define TERMIOS_TTY_DRIVER
-+#endif
- #define HAVE_BSD_SIGNALS
- /* #define USE_XON_XOFF */
-
-@@ -80,6 +84,10 @@
- # if !defined (O_NDELAY)
- # define O_NDELAY O_NONBLOCK /* Posix-style non-blocking i/o */
- # endif /* O_NDELAY */
-+#else
-+# ifdef TERMIOS_TTY_DRIVER
-+# include <termios.h>
-+# endif /* !TERMIOS_MISSING */
- #endif /* _POSIX_VERSION */
-
- /* Other (BSD) machines use sgtty. */
-@@ -133,7 +141,7 @@
- # endif /* USGr3 */
- #endif /* USG && hpux */
-
--#if defined (_POSIX_VERSION) || defined (USGr3)
-+#if defined (_POSIX_VERSION) || defined (USGr3) || defined(__linux__)
- # include <dirent.h>
- # define direct dirent
- # if defined (_POSIX_VERSION)
-@@ -280,7 +288,7 @@
- static FILE *in_stream, *out_stream;
-
- /* The names of the streams that we do input and output to. */
--FILE *rl_instream = stdin, *rl_outstream = stdout;
-+FILE *rl_instream = NULL, *rl_outstream = NULL;
-
- /* Non-zero means echo characters as they are read. */
- int readline_echoing_p = 1;
-@@ -1152,6 +1160,8 @@
- {
- /* Find out if we are running in Emacs. */
- running_in_emacs = getenv ("EMACS");
-+ rl_instream = stdin;
-+ rl_outstream = stdout;
-
- /* Allocate data structures. */
- if (!rl_line_buffer)
-@@ -2505,7 +2515,11 @@
-
- tio.c_lflag &= ~(ICANON | ECHO);
-
-- if (otio.c_cc[VEOF] != _POSIX_VDISABLE)
-+#ifdef ONLCR
-+ tio.c_oflag |= OPOST|ONLCR;
+$NetBSD: patch-aj,v 1.2 1999/11/26 22:12:37 hubertf Exp $
+
+diff -x *.orig -urN ./icb/strings.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/strings.c
+--- ./icb/strings.c Fri Feb 24 22:20:30 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/strings.c Fri Nov 26 22:56:28 1999
+@@ -333,6 +333,7 @@
+ /* cat multiple strings into one */
+ /* call with strscat(dest, src, src, ...) */
+
++#if 0
+ char *
+ strscat(va_alist)
+ va_dcl
+@@ -357,6 +358,7 @@
+ *dest = '\0';
+ return(dest);
+ }
+#endif
-+
-+ if ((unsigned char)otio.c_cc[VEOF] != (unsigned char)_POSIX_VDISABLE)
- eof_char = otio.c_cc[VEOF];
- #if defined (USE_XON_XOFF)
+ char *basename(path)
+ char *path;
diff --git a/net/icb/patches/patch-ak b/net/icb/patches/patch-ak
index e433c390fff..7521275076f 100644
--- a/net/icb/patches/patch-ak
+++ b/net/icb/patches/patch-ak
@@ -1,47 +1,59 @@
-$NetBSD: patch-ak,v 1.1 1999/09/29 00:41:26 christos Exp $
---- tcl/strerror.c.orig Fri Feb 24 16:19:50 1995
-+++ tcl/strerror.c Tue Sep 28 18:36:37 1999
-@@ -20,6 +20,7 @@
+$NetBSD: patch-ak,v 1.2 1999/11/26 22:12:38 hubertf Exp $
+
+diff -x *.orig -urN ./icb/unix.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/unix.c
+--- ./icb/unix.c Fri Feb 24 22:20:31 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/icb/unix.c Fri Nov 26 22:56:29 1999
+@@ -4,6 +4,8 @@
+ /* This file contains routines that are unix dependent. */
+ /* Eventually, most unixisms should be moved here. */
+
++#include <sys/types.h>
++#include <sys/param.h>
#include <stdio.h>
- #include <string.h>
-
-+#if !defined(BSD4_4) && !defined(__linux__)
- /*
- * List of known errors:
- */
-@@ -138,3 +139,4 @@
- (void) sprintf(defaultMsg, "unknown error (%d)", error);
- return defaultMsg;
+ #include "icb.h"
+ #include "externs.h"
+@@ -13,6 +15,14 @@
+ #undef stty
+ #undef gtty
+
++#if defined(__linux__)
++#include <termios.h>
++#include <sys/ioctl.h>
++#define TTYSTRUCT termios
++#define stty(fd,buf) tcgetattr((fd), (buf))
++#define gtty(fd,buf) tcsetattr((fd), TCSANOW, (buf))
++#define SYSV
++#else
+ #ifndef SYSV
+
+ #ifdef linux
+@@ -30,6 +40,7 @@
+ #define stty(fd,buf) ioctl((fd),TCSETA,(buf))
+ #define gtty(fd,buf) ioctl((fd),TCGETA,(buf))
+ #endif /* SYSV */
++#endif /* __linux__ */
+
+ char *getlogin();
+
+@@ -49,8 +60,10 @@
+ if (((loginid = getlogin()) == NULL) || *loginid == '\0')
+ if ((pw = getpwuid(getuid())) == NULL)
+ loginid = NULL;
+- else
+- loginid = pw->pw_name;
++ else {
++ loginid = malloc(strlen(pw->pw_name) + 1);
++ strcpy(loginid, pw->pw_name);
++ }
+ return(loginid);
}
-+#endif
---- tcl/tclGlob.c.orig Tue Sep 28 18:37:08 1999
-+++ tcl/tclGlob.c Tue Sep 28 18:39:13 1999
-@@ -28,6 +28,12 @@
- #include <sys/stat.h>
- #include <tcl.h>
-
-+#ifdef __linux__
-+#define DIRNAMLEN(d) strlen((d)->d_name)
-+#else
-+#define DIRNAMLEN(d) ((d)->d_namlen)
-+#endif
-+
- /*
- * The structure below is used to keep track of a globbing result
- * being built up (i.e. a partial list of file names). The list
-@@ -298,12 +304,12 @@
- if (Tcl_StringMatch(entryPtr->d_name, pattern)) {
- if (*p == 0) {
- AppendResult(dir, entryPtr->d_name,
-- (int) entryPtr->d_namlen, resPtr);
-+ (int) DIRNAMLEN(entryPtr), resPtr);
- } else {
-- if ((l1+entryPtr->d_namlen+2) <= STATIC_SIZE) {
-+ if ((l1+DIRNAMLEN(entryPtr)+2) <= STATIC_SIZE) {
- newDir = static1;
- } else {
-- newDir = malloc((unsigned) (l1+entryPtr->d_namlen+2));
-+ newDir = malloc((unsigned) (l1+DIRNAMLEN(entryPtr)+2));
- }
- sprintf(newDir, "%s%s/", dir, entryPtr->d_name);
- result = DoGlob(interp, newDir, p+1, resPtr);
+
+@@ -181,7 +194,7 @@
+
+ getwinsize()
+ {
+-#ifndef NOWINSIZE
++#ifdef TIOCGWINSZ
+ struct winsize win;
+
+ /* get tty settings */
diff --git a/net/icb/patches/patch-al b/net/icb/patches/patch-al
index 7ebb270e8f5..d5b1538923b 100644
--- a/net/icb/patches/patch-al
+++ b/net/icb/patches/patch-al
@@ -1,26 +1,14 @@
-$NetBSD: patch-al,v 1.1 1999/09/29 00:41:26 christos Exp $
+$NetBSD: patch-al,v 1.2 1999/11/26 22:12:38 hubertf Exp $
---- murgil/serverserve.c.orig Tue Sep 28 19:20:05 1999
-+++ murgil/serverserve.c Tue Sep 28 19:21:56 1999
-@@ -20,6 +20,9 @@
- int timeisup;
-
- sighandler gotalarm();
-+#ifndef __FDS_BITS
-+# define __FDS_BITS(set) ((set)->fds_bits)
-+#endif
-
- serverserve()
+diff -x *.orig -urN ./murgil/getrname.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/murgil/getrname.c
+--- ./murgil/getrname.c Fri Feb 24 22:19:41 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/murgil/getrname.c Fri Nov 26 22:56:29 1999
+@@ -14,7 +14,7 @@
{
-@@ -81,9 +84,9 @@
-
- /* examine set of file descriptors */
- for (b = 0, y = 0; b <= (howmany(highestfd, 32) - 1); b++, y += 32) {
-- if (!fdr.fds_bits[b])
-+ if (!__FDS_BITS(&fdr)[b])
- continue;
-- bits = fdr.fds_bits[b];
-+ bits = __FDS_BITS(&fdr)[b];
- for (x = y; bits; x++, bits >>= 01)
- if (bits & 01)
- if (x == port_fd) {
+ static char rname[24];
+ struct hostent *host;
+-#if defined(linux)
++#if defined(linux) || defined(__NetBSD__)
+ #define PEER_CAST (struct sockaddr *)
+ #define HOST_CAST (char *)
+ #else
diff --git a/net/icb/patches/patch-am b/net/icb/patches/patch-am
new file mode 100644
index 00000000000..baa007afec2
--- /dev/null
+++ b/net/icb/patches/patch-am
@@ -0,0 +1,27 @@
+$NetBSD: patch-am,v 1.1 1999/11/26 22:12:38 hubertf Exp $
+
+diff -x *.orig -urN ./murgil/serverserve.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/murgil/serverserve.c
+--- ./murgil/serverserve.c Fri Feb 24 22:19:44 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/murgil/serverserve.c Fri Nov 26 22:56:30 1999
+@@ -20,6 +20,9 @@
+ int timeisup;
+
+ sighandler gotalarm();
++#ifndef __FDS_BITS
++# define __FDS_BITS(set) ((set)->fds_bits)
++#endif
+
+ serverserve()
+ {
+@@ -81,9 +84,9 @@
+
+ /* examine set of file descriptors */
+ for (b = 0, y = 0; b <= (howmany(highestfd, 32) - 1); b++, y += 32) {
+- if (!fdr.fds_bits[b])
++ if (!__FDS_BITS(&fdr)[b])
+ continue;
+- bits = fdr.fds_bits[b];
++ bits = __FDS_BITS(&fdr)[b];
+ for (x = y; bits; x++, bits >>= 01)
+ if (bits & 01)
+ if (x == port_fd) {
diff --git a/net/icb/patches/patch-an b/net/icb/patches/patch-an
new file mode 100644
index 00000000000..f04401c28cd
--- /dev/null
+++ b/net/icb/patches/patch-an
@@ -0,0 +1,68 @@
+$NetBSD: patch-an,v 1.1 1999/11/26 22:12:38 hubertf Exp $
+
+diff -x *.orig -urN ./readline/readline.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/readline/readline.c
+--- ./readline/readline.c Fri Feb 24 22:20:03 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/readline/readline.c Fri Nov 26 22:56:30 1999
+@@ -48,7 +48,11 @@
+ # include <unistd.h>
+ #endif
+
++#if !defined(__linux__)
+ #define NEW_TTY_DRIVER
++#else
++#define TERMIOS_TTY_DRIVER
++#endif
+ #define HAVE_BSD_SIGNALS
+ /* #define USE_XON_XOFF */
+
+@@ -80,6 +84,10 @@
+ # if !defined (O_NDELAY)
+ # define O_NDELAY O_NONBLOCK /* Posix-style non-blocking i/o */
+ # endif /* O_NDELAY */
++#else
++# ifdef TERMIOS_TTY_DRIVER
++# include <termios.h>
++# endif /* !TERMIOS_MISSING */
+ #endif /* _POSIX_VERSION */
+
+ /* Other (BSD) machines use sgtty. */
+@@ -133,7 +141,7 @@
+ # endif /* USGr3 */
+ #endif /* USG && hpux */
+
+-#if defined (_POSIX_VERSION) || defined (USGr3)
++#if defined (_POSIX_VERSION) || defined (USGr3) || defined(__linux__)
+ # include <dirent.h>
+ # define direct dirent
+ # if defined (_POSIX_VERSION)
+@@ -280,7 +288,7 @@
+ static FILE *in_stream, *out_stream;
+
+ /* The names of the streams that we do input and output to. */
+-FILE *rl_instream = stdin, *rl_outstream = stdout;
++FILE *rl_instream = NULL, *rl_outstream = NULL;
+
+ /* Non-zero means echo characters as they are read. */
+ int readline_echoing_p = 1;
+@@ -1152,6 +1160,8 @@
+ {
+ /* Find out if we are running in Emacs. */
+ running_in_emacs = getenv ("EMACS");
++ rl_instream = stdin;
++ rl_outstream = stdout;
+
+ /* Allocate data structures. */
+ if (!rl_line_buffer)
+@@ -2505,7 +2515,11 @@
+
+ tio.c_lflag &= ~(ICANON | ECHO);
+
+- if (otio.c_cc[VEOF] != _POSIX_VDISABLE)
++#ifdef ONLCR
++ tio.c_oflag |= OPOST|ONLCR;
++#endif
++
++ if ((unsigned char)otio.c_cc[VEOF] != (unsigned char)_POSIX_VDISABLE)
+ eof_char = otio.c_cc[VEOF];
+
+ #if defined (USE_XON_XOFF)
diff --git a/net/icb/patches/patch-ao b/net/icb/patches/patch-ao
new file mode 100644
index 00000000000..1a905251836
--- /dev/null
+++ b/net/icb/patches/patch-ao
@@ -0,0 +1,18 @@
+$NetBSD: patch-ao,v 1.1 1999/11/26 22:12:38 hubertf Exp $
+
+diff -x *.orig -urN ./tcl/strerror.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/tcl/strerror.c
+--- ./tcl/strerror.c Fri Feb 24 22:19:50 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/tcl/strerror.c Fri Nov 26 22:56:30 1999
+@@ -20,6 +20,7 @@
+ #include <stdio.h>
+ #include <string.h>
+
++#if !defined(BSD4_4) && !defined(__linux__)
+ /*
+ * List of known errors:
+ */
+@@ -138,3 +139,4 @@
+ (void) sprintf(defaultMsg, "unknown error (%d)", error);
+ return defaultMsg;
+ }
++#endif
diff --git a/net/icb/patches/patch-ap b/net/icb/patches/patch-ap
new file mode 100644
index 00000000000..caaae0474a7
--- /dev/null
+++ b/net/icb/patches/patch-ap
@@ -0,0 +1,60 @@
+$NetBSD: patch-ap,v 1.1 1999/11/26 22:12:38 hubertf Exp $
+
+diff -x *.orig -urN ./tcl/tclCmdAH.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/tcl/tclCmdAH.c
+--- ./tcl/tclCmdAH.c Fri Feb 24 22:19:53 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/tcl/tclCmdAH.c Fri Nov 26 22:56:28 1999
+@@ -38,9 +38,22 @@
+ #include <sys/wait.h>
+ #include "tclInt.h"
+
++#ifdef __NetBSD__
++#define unix
++#endif
++
++#if (defined(__unix__) || defined(unix)) && !defined(USG)
++#include <sys/param.h>
++#include <unistd.h>
++#endif
++
+ extern int errno;
++#if !(defined(BSD) && BSD >= 199306)
+ extern long lseek();
++#endif
++#ifndef BSD4_4
+ extern char *mktemp();
++#endif
+
+ /*
+ *----------------------------------------------------------------------
+@@ -430,7 +443,7 @@
+ int pid = -1; /* -1 means child process doesn't
+ * exist (yet). Non-zero gives its
+ * id (0 only in child). */
+- union wait status;
++ int status;
+ char *cmdName, *execName;
+
+ /*
+@@ -501,8 +514,13 @@
+ } else {
+ char tmp[sizeof(TMP_FILE_NAME) + 1];
+ strcpy(tmp, TMP_FILE_NAME);
++#ifdef BSD4_4
++ mkstemp(tmp);
++ stdIn[0] = mkstemp(tmp);
++#else
+ mktemp(tmp);
+ stdIn[0] = open(tmp, O_RDWR|O_CREAT, 0);
++#endif
+ if (stdIn[0] < 0) {
+ sprintf(interp->result,
+ "couldn't create input file for \"%.50s\" command: %.50s",
+@@ -642,7 +660,7 @@
+ sprintf(interp->result, "command terminated abnormally");
+ result = TCL_ERROR;
+ }
+- result = status.w_retcode;
++ result = WEXITSTATUS(status);
+ }
+ if (stdIn[0] != -1) {
+ close(stdIn[0]);
diff --git a/net/icb/patches/patch-aq b/net/icb/patches/patch-aq
new file mode 100644
index 00000000000..e656a0c1230
--- /dev/null
+++ b/net/icb/patches/patch-aq
@@ -0,0 +1,35 @@
+$NetBSD: patch-aq,v 1.1 1999/11/26 22:12:38 hubertf Exp $
+
+diff -x *.orig -urN ./tcl/tclGlob.c /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/tcl/tclGlob.c
+--- ./tcl/tclGlob.c Fri Feb 24 22:19:55 1995
++++ /usr/pkgsrc/net/icb/work.i386.unpatched/icb-5.0.9/tcl/tclGlob.c Fri Nov 26 22:56:30 1999
+@@ -28,6 +28,12 @@
+ #include <sys/stat.h>
+ #include <tcl.h>
+
++#ifdef __linux__
++#define DIRNAMLEN(d) strlen((d)->d_name)
++#else
++#define DIRNAMLEN(d) ((d)->d_namlen)
++#endif
++
+ /*
+ * The structure below is used to keep track of a globbing result
+ * being built up (i.e. a partial list of file names). The list
+@@ -298,12 +304,12 @@
+ if (Tcl_StringMatch(entryPtr->d_name, pattern)) {
+ if (*p == 0) {
+ AppendResult(dir, entryPtr->d_name,
+- (int) entryPtr->d_namlen, resPtr);
++ (int) DIRNAMLEN(entryPtr), resPtr);
+ } else {
+- if ((l1+entryPtr->d_namlen+2) <= STATIC_SIZE) {
++ if ((l1+DIRNAMLEN(entryPtr)+2) <= STATIC_SIZE) {
+ newDir = static1;
+ } else {
+- newDir = malloc((unsigned) (l1+entryPtr->d_namlen+2));
++ newDir = malloc((unsigned) (l1+DIRNAMLEN(entryPtr)+2));
+ }
+ sprintf(newDir, "%s%s/", dir, entryPtr->d_name);
+ result = DoGlob(interp, newDir, p+1, resPtr);
+