From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5195 invoked from network); 1 Dec 2008 12:21:30 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 1 Dec 2008 12:21:30 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 24624 invoked from network); 1 Dec 2008 12:21:22 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 1 Dec 2008 12:21:22 -0000 Received: (qmail 12889 invoked by alias); 1 Dec 2008 12:21:16 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 26103 Received: (qmail 12877 invoked from network); 1 Dec 2008 12:21:16 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 1 Dec 2008 12:21:16 -0000 Received: from cluster-g.mailcontrol.com (cluster-g.mailcontrol.com [208.87.233.190]) by bifrost.dotsrc.org (Postfix) with ESMTPS id 992FD80525B6 for ; Mon, 1 Dec 2008 13:21:10 +0100 (CET) Received: from rly30g.srv.mailcontrol.com (localhost.localdomain [127.0.0.1]) by rly30g.srv.mailcontrol.com (MailControl) with ESMTP id mB1CKiZ1022120 for ; Mon, 1 Dec 2008 12:21:07 GMT Received: from submission.mailcontrol.com (submission.mailcontrol.com [86.111.216.190]) by rly30g.srv.mailcontrol.com (MailControl) id mB1CKN8Y020472 for zsh-workers@sunsite.dk; Mon, 1 Dec 2008 12:20:23 GMT Received: from cameurexb01.EUROPE.ROOT.PRI ([193.128.72.68]) by [10.71.0.140] (envelope-sender Peter.Stephenson@csr.com) (MIMEDefang) with ESMTP id mB1CKKhA020028; Mon, 01 Dec 2008 12:20:23 +0000 (GMT) Received: from news01 ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.3959); Mon, 1 Dec 2008 12:20:19 +0000 Date: Mon, 1 Dec 2008 12:20:19 +0000 From: Peter Stephenson To: "Peter A. Castro" , zsh-workers@sunsite.dk Subject: Re: D03 test hang on cygwin with latest sources Message-ID: <20081201122019.18043478@news01> In-Reply-To: References: <20a807210811202008o34865319qe1840896992ac48d@mail.gmail.com> <081120211244.ZM30106@torch.brasslantern.com> <20081124173230.31422068@news01> <20081124223104.GA37873@redoubt.spodhuis.org> <200811250956.mAP9ukDw026001@news01.csr.com> Organization: CSR X-Mailer: Claws Mail 3.5.0 (GTK+ 2.12.8; i386-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 01 Dec 2008 12:20:19.0530 (UTC) FILETIME=[2CF362A0:01C953AF] X-Scanned-By: MailControl A_08_51_00 (www.mailcontrol.com) on 10.71.1.140 X-Virus-Scanned: ClamAV 0.92.1/8700/Mon Dec 1 11:56:03 2008 on bifrost X-Virus-Status: Clean On Tue, 25 Nov 2008 15:26:09 -0800 (PST) "Peter A. Castro" wrote: > Well, configure.ac has an explicit check for cygwin and disables the feature: > > dnl ----------- > dnl named FIFOs > dnl ----------- > AC_CACHE_CHECK(if named FIFOs work, > zsh_cv_sys_fifo, > [if test "$host_os" = cygwin; then > zsh_cv_sys_fifo=no > else So that didn't take long to check, after all... > The other thing about this is that the fifo test code fails but the > reason appears to be a race condition between the parent and child > creating the fifo. I've modified the example thus: With most FIFO implementations this wouldn't be necessary since after the FIFO is created both the read and the write would block if there's nothing at the other end. I therefore don't know enough to provide a robust fix. I've simply changed the Cygwin-specific code above. > With the above changes the 'foo' test above works, though > Test/C02cond.ztst still generates an error. I fixed that, so all tests pass (except the multibyte test which is skipped). Thanks for the notes. By the way, do you know what the status is under Vista? I'm still getting more than occasional fatal DLL conflicts. Last time I checked the only fixes for this were ad-hoc magic. Index: configure.ac =================================================================== RCS file: /cvsroot/zsh/zsh/configure.ac,v retrieving revision 1.113 diff -u -r1.113 configure.ac --- configure.ac 18 Nov 2008 10:14:35 -0000 1.113 +++ configure.ac 1 Dec 2008 12:12:22 -0000 @@ -1787,9 +1787,17 @@ AH_TEMPLATE([PATH_DEV_FD], [Define to the path of the /dev/fd filesystem.]) AC_CACHE_CHECK(for /dev/fd filesystem, zsh_cv_sys_path_dev_fd, +[if test "$host_os" = cygwin; then +dnl In current (2008/12/01) versions of Cygwin these are present but don't +dnl seem to work smoothly for process substitution; no great surprise +dnl since getting processes to work at all on Cygwin is a big challenge. +dnl We'll rely on FIFOs, since they do what we need. +zsh_cv_sys_path_dev_fd=no +else [for zsh_cv_sys_path_dev_fd in /proc/self/fd /dev/fd no; do test x`echo ok|(exec 3<&0; cat $zsh_cv_sys_path_dev_fd/3 2>/dev/null;)` = xok && break - done]) + done] +fi]) if test x$zsh_cv_sys_path_dev_fd != xno; then AC_DEFINE_UNQUOTED(PATH_DEV_FD, "$zsh_cv_sys_path_dev_fd") fi @@ -1954,10 +1962,13 @@ dnl ----------- dnl named FIFOs dnl ----------- +dnl +dnl Named FIFOs work well enough on recent versions of Cygwin +dnl to provide what we want. Simply enable them. AC_CACHE_CHECK(if named FIFOs work, zsh_cv_sys_fifo, [if test "$host_os" = cygwin; then -zsh_cv_sys_fifo=no +zsh_cv_sys_fifo=yes else AC_TRY_RUN([ #include -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070