Subject: Re: Cross-building from FreeBSD: file locking on METALOG
To: Jason Thorpe <thorpej@shagadelic.org>
From: Andrew Reilly <andrew-netbsd@areilly.bpc-users.org>
List: tech-toolchain
Date: 06/27/2006 10:28:57
On Mon, Jun 26, 2006 at 10:54:24AM -0700, Jason Thorpe wrote:
> 
> On Jun 25, 2006, at 9:28 PM, Andrew Reilly wrote:
> 
> >That seems like a really neat idea, except that apparently
> >fcntl(.., F_SETLOCKW,..) doesn't work on regular files on
> >FreeBSD at the moment.
> 
> Seems like a pretty major issue for FreeBSD to have a broken  
> F_SETLKW.

I must apologise for my rashness: I forgot that I was getting
this error on an NFS-mounted tree.  It all works beautifully on
a local file system.  Does NetBSD's file locking work any better
over NFS?  Could cat -l reasonably be extended to use a more
NFS-friendly scheme, like dot-lock files?  (I know they have
issues too...)

> Seems like they're the odd man out; everything else that  
> we support as a build host has a working F_SETLKW, it is standards- 
> defined, so I don't see why we should bend over backwards to support  
> a utterly broken host system.

Indeed, you should not.

I still like lockf(1) more than cat -l, now that I've seen both,
but they both fail to work on my NFS-mounted tree just the
same...

For now, I'll just make obj a local file system, and all should
be well, I hope.

Cheers,

-- 
Andrew