delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/04/17/06:02:12

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Fri, 17 Apr 2009 12:01:48 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: [1.7] flock change breaks autotools 'make -j2'
Message-ID: <20090417100148.GD5200@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <loom DOT 20090416T201917-225 AT post DOT gmane DOT org>
MIME-Version: 1.0
In-Reply-To: <loom.20090416T201917-225@post.gmane.org>
User-Agent: Mutt/1.5.19 (2009-02-20)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Apr 16 20:39, Eric Blake wrote:
> This change in cygwin 1.7:
> 
> - File locking is now advisory, not mandatory anymore.  The fcntl(2) and
>   the new lockf(2) APIs create and maintain locks with POSIX semantics,
>   the flock(2) API creates and maintains locks with BSD semantics.
>   POSIX and BSD locks are independent of each other.
> 
> is causing parallel make bugs in autotooled projects:
> 
> http://lists.gnu.org/archive/html/bug-automake/2009-04/msg00048.html
> 
> The problem is that perl's flock is no longer locking files the way it
> used to, so parallel instances of autom4te (the engine behind both
> autoconf and automake) end up stomping on each others' output.  I
> don't know if it something that needs to be fixed in perl, in
> automake's XFile::lock wrapper around perl's flock, or even in cygwin
> itself.  But it seems like if two instances of the same perl program
> are using the same advisory locking mechanism, that they should keep
> each other out of the file properly (advisory means that processes not
> using flock can still stomp on the file, but not other processes using
> the same locking mechanism).

Default question:  Do you have a simple testcase to reproduce this
problem?  I'm going to play with the lock.pl perl script from
http://lists.gnu.org/archive/html/bug-automake/2009-04/msg00053.html but
I don't know if I can get it working.  Perl isn't exactly my domain.
I'd prefer a testcase in C.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019