From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.devel Subject: Re: Failure in building Emacs 23.0.50 on Cygwin (fwd) Date: Tue, 04 Sep 2007 14:36:58 -0700 Message-ID: <200709042136.l84Lawms007683@oogie-boogie.ics.uci.edu> References: <20070903075037.2652@blackhawk> <20070903092334.2296@blackhawk> <200709041620.l84GKRKJ026897@oogie-boogie.ics.uci.edu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1188941879 29541 80.91.229.12 (4 Sep 2007 21:37:59 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 4 Sep 2007 21:37:59 +0000 (UTC) Cc: Eli Zaretskii , "d.henman" , emacs-devel@gnu.org To: Angelo Graziosi Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 04 23:37:56 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1ISg5p-0000rP-Qs for ged-emacs-devel@m.gmane.org; Tue, 04 Sep 2007 23:37:54 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ISg5o-0008Op-9T for ged-emacs-devel@m.gmane.org; Tue, 04 Sep 2007 17:37:52 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1ISg5P-0008Fb-6A for emacs-devel@gnu.org; Tue, 04 Sep 2007 17:37:27 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1ISg5O-0008FB-9y for emacs-devel@gnu.org; Tue, 04 Sep 2007 17:37:26 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ISg5N-0008Es-Tv for emacs-devel@gnu.org; Tue, 04 Sep 2007 17:37:25 -0400 Original-Received: from oogie-boogie.ics.uci.edu ([128.195.1.41]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1ISg5K-0008Gm-6y; Tue, 04 Sep 2007 17:37:22 -0400 Original-Received: from mothra.ics.uci.edu (mothra.ics.uci.edu [128.195.6.93]) by oogie-boogie.ics.uci.edu (8.13.6/8.13.6) with ESMTP id l84Lawms007683; Tue, 4 Sep 2007 14:36:58 -0700 (PDT) In-Reply-To: (Angelo Graziosi's message of "Tue\, 4 Sep 2007 22\:53\:47 +0200 \(MET DST\)") Original-Lines: 55 X-ICS-MailScanner: Found to be clean X-ICS-MailScanner-SpamCheck: not spam, SpamAssassin (score=-1.44, required 5, autolearn=disabled, ALL_TRUSTED -1.44) X-ICS-MailScanner-From: dann@mothra.ics.uci.edu X-Detected-Kernel: Solaris 9 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:77772 Archived-At: Angelo Graziosi writes: > On Tue, 4 Sep 2007, Dan Nicolaescu wrote: > > > "d.henman" writes: > > > > > Angelo, > > > > > > content wise it looks good to me, but I think that changing it to the following > > > format, same content as your patch (see modifed patch below ), but this format makes it easier to understand and would give it more robustness for future mainenance and any possible changes and extensions for CYGWIN specific issues. > > > > > > Also I would like to wait and get a response from the cygwin developers, before any commit is made. > > > > > > Regards, > > > Darel Henman > > > > > > ---------------------------------------------------------------- > > > --- term.c 2007-08-30 06:46:50.000000000 +0900 > > > +++ /tmp/term.c.fixed 2007-09-03 09:15:22.915209300 +0900 > > > @@ -3131,6 +3131,10 @@ > > > setpgrp (); > > > no_controlling_tty = 1; > > > #else > > > +#ifdef CYGWIN > > > + setsid (); > > > + no_controlling_tty = 1; > > > +#else > > > #ifdef TIOCNOTTY /* Try BSD ioctls. */ > > > sigblock (sigmask (SIGTTOU)); > > > fd = emacs_open ("/dev/tty", O_RDWR, 0); > > > @@ -3145,6 +3149,7 @@ > > > /* Unknown system. */ > > > croak (); > > > #endif /* ! TIOCNOTTY */ > > > +#endif /* ! CYGWIN */ > > > #endif /* ! USG */ > > > } > > > #endif > > > > > > Just my curiosity, does this patch make emacs work on cygwin? > > If it doesn't, is this function called before things go bad? > > > IF 'setpgrp' is similar to 'setsid' > (http://www.opengroup.org/onlinepubs/009695399/functions/setsid.html) AND > IF Cygwin list suggests to use 'setsid' to dissociate TTY > (http://cygwin.com/ml/cygwin/2007-09/msg00026.html) THEN > > the above patch is quite natural... OR NOT? You have not answered the fundamental question: does the patch work? I don't think this code path is exercised if you run in a window system, it will probably only be used if you use "emacsclient -t" or "emacs -nw".