*BSD News Article 24506


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!sgiblab!swrinde!cs.utexas.edu!not-for-mail
From: mike.long@analog.com (Mike Long)
Newsgroups: comp.os.386bsd.apps
Subject: Making Kermit and UUCP lockfile conventions.
Date: 29 Nov 1993 01:48:57 -0600
Organization: UTexas Mail-to-News Gateway
Lines: 32
Sender: daemon@cs.utexas.edu
Message-ID: <9311290747.AA03659@cthulhu>
Reply-To: Mike Long <Mike.Long@analog.com>
NNTP-Posting-Host: news.cs.utexas.edu

I'm learning a lot about UUCP lockfile conventions while trying to
build C-Kermit 5A(189).  The convention used by tip(1) and cu(1) in
NetBSD-0.9 is that lockfiles are kept in /var/spool/lock in files
named 'LCK..<device>', where <device> is the name of the serial port
in use (e.g., tty00).

C-Kermit, on the other hand, seems to expect lockfile names using the
SVR4 format, which is something like 'LK.<x>.<y>.<z>'.  Two of the
<x>/<y>/<z> variables are the major and minor device numbers of the
serial port in use; I can't remember what the other one is at the
moment.  C-Kermit uses this convention when built using 'make bsd44'.
Note:  In order to get the correct lock directory, the command
actually has to be:

make bsd44 KFLAGS='-DLOCK_DIR=\\\"/var/spool/lock\\\"'

So, should I dig into the Kermit source to make it match tip(1)?
Or, should I update my system to match what C-Kermit thinks is the
standard BSD 4.4 lockfile system?  In which direction is NetBSD going?

The SVR4 system seems better, because it can't be broken when you have
two devices with the same major/minor numbers but different names, as
is the case with /dev/tty00 and /dev/com0.

(P.S.  I downloaded the 'ported' C-Kermit source from
alpha.gnu.ai.mit.edu.  The included binary doesn't even get the lock
directory right; it uses /var/spool/uucp.)
-- 
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);