Subject: C-Kermit 5A(189) patches for 12/4 NetBSD-current
To: None <current-users@sun-lamp.cs.berkeley.edu>
From: Mike Long <mike.long@analog.com>
List: current-users
Date: 12/11/1993 03:12:31
I finally got Kermit working tonight, and found a few minor problems
during the process. Apply the context diffs below to the existing
port found at:
sun-lamp.cs.berkeley.edu:/pub/NetBSD-current/tar_files/othersrc/kermit.tar.gz
These patches fix the following problems:
+ support for 57600 and 115200 bps was partial, and broken anyway
+ Kermit was still using the wrong UUCP lockfile names
+ UUCP lockfiles need to be user-readable in order for tip to work,
since tip opens lockfiles for both reading & writing.
+ If you build it with -DNOSERVER, the SHOW PROTOCOL report was
messed up.
I don't know if I should send these to the Kermit developers or not,
but I compiled my patched kermit with the additional flags -DNODEBUG,
-DMINIDIAL, and -DNOSERVER, and it works fine (using it now, in fact.)
Some of the __386BSD__ symbols will have to become __NetBSD__ symbols
soon.
*** Makefile.orig Sun Nov 7 05:47:37 1993
--- Makefile Sat Dec 11 01:53:35 1993
***************
*** 5,10 ****
--- 5,13 ----
ckuus3.c ckuus4.c ckuus5.c ckuus6.c \
ckuus7.c ckuusx.c ckuusy.c ckuusr.c \
ckucon.c ckudia.c ckuscr.c ckcnet.c
+ BINDIR=/usr/local/bin
+ BINOWN=uucp
+ BINMODE=4511
MAN1= kermit.0
*** ckutio.c.orig Sun Nov 7 05:48:52 1993
--- ckutio.c Sat Dec 11 01:40:03 1993
***************
*** 2357,2363 ****
--- 2357,2365 ----
#ifdef SVR4 /* Lockfile uses device numbers. */
#ifndef LFDEVNO /* Define this for SVR4 */
#ifndef AIXRS /* But not for RS/6000 AIX 3.2 */
+ #ifndef __386BSD__ /* Nor for 386/NetBSD */
#define LFDEVNO /* If anybody else needs it, */
+ #endif /* __386BSD__ */
#endif /* AIXRS */
#endif /* LFDEVNO */ /* define it here or on CC */
#endif /* SVR4 */ /* command line. */
***************
*** 2484,2490 ****
--- 2486,2496 ----
debug(F110,"ttlock tmpnam",tmpnam,0);
priv_on(); /* Turn on privileges if possible. */
+ #ifdef __386BSD__
+ lockfd = creat(tmpnam, 0644); /* Try to create temp lock file. */
+ #else
lockfd = creat(tmpnam, 0444); /* Try to create temp lock file. */
+ #endif /* __386BSD__ */
if (lockfd < 0) { /* Create failed. */
debug(F111,"ttlock creat failed",tmpnam,errno);
if (errno == ENOENT) {
***************
*** 3556,3561 ****
--- 3562,3575 ----
#endif /* EXTB */
#endif /* B38400 */
#endif /* MINIX */
+
+ #ifdef B57600
+ case B57600: ss = 57600L; break;
+ #endif /* B57600 */
+
+ #ifdef B115200
+ case B115200: ss = 115200L; break;
+ #endif /* B115200 */
#ifdef HPUX
#ifdef _B57600
*** ckuus3.c.orig Sun Nov 7 05:49:00 1993
--- ckuus3.c Sat Dec 11 01:47:19 1993
***************
*** 207,212 ****
--- 207,215 ----
struct keytab spdtab[] = {
"0", 0, CM_INV,
"110", 11, 0,
+ #ifdef BSD44
+ "115200",11520, 0,
+ #endif
#ifdef HPUX
"115200",11520, 0,
#else
***************
*** 247,252 ****
--- 250,258 ----
#endif /* NEXT */
#endif /* HPUX */
#endif /* OS2 */
+ #ifdef BSD44
+ "57600", 5760, 0,
+ #endif /* BSD44 */
"600", 60, 0,
#ifdef OS2
"7200", 720, 0,
***************
*** 255,264 ****
#ifdef ANYBSD
"75/1200",888, 0, /* Special code "888" for split speed */
#endif /* ANYBSD */
- #ifdef BSD44
- "57600", 5760, 0,
- "115200", 115200, 0,
- #endif /* BSD44 */
#ifdef OS2
#ifdef __32BIT__
"76800", 7680, 0,
--- 261,266 ----
*** ckuus4.c.orig Sun Nov 7 05:49:02 1993
--- ckuus4.c Fri Dec 10 22:08:24 1993
***************
*** 1422,1430 ****
else
printf("\n Timeout (used=%2d):%7d%9d ", timint, rtimo, pkttim);
#ifndef NOSERVER
! printf(" Server Timeout:%4d\n",srvtim);
#endif /* NOSERVER */
! printf( " Padding: %11d%9d", npad, mypadn);
if (bctr == 4)
printf(" Block Check: blank-free-2\n");
else
--- 1422,1430 ----
else
printf("\n Timeout (used=%2d):%7d%9d ", timint, rtimo, pkttim);
#ifndef NOSERVER
! printf(" Server Timeout:%4d",srvtim);
#endif /* NOSERVER */
! printf("\n Padding: %11d%9d", npad, mypadn);
if (bctr == 4)
printf(" Block Check: blank-free-2\n");
else
--
Mike Long Mike.Long@Analog.com
VLSI Design Engineer voice: (617)461-4030
Analog Devices, SPD Div. FAX: (617)461-3010
Norwood, MA 02062 *this = !opinion(Analog);
------------------------------------------------------------------------------