delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/05/31/12:17:45

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <3B166D65.1F0A8935@bellatlantic.net>
Date: Thu, 31 May 2001 12:12:21 -0400
From: "John W. Kennedy" <jwkenned AT bellatlantic DOT net>
Reply-To: jwkenne AT attglobal DOT net
X-Mailer: Mozilla 4.75 [en] (Win95; U)
X-Accept-Language: en
MIME-Version: 1.0
To: cygwin AT cygwin DOT com, mingw-users AT lists DOT sourceforge DOT net
CC: Charles Wilson <cwilson AT ece DOT gatech DOT edu>
Subject: Re: 1.3.2 Catch-22 in tmpnam/tmpfile with gcc -mno-cygwin
References: <3B1510F5 DOT 8BCF31AF AT bellatlantic DOT net> <20010530130630 DOT C19066 AT redhat DOT com> <3B15394E DOT E07EBB39 AT yahoo DOT com> <3B162F6B DOT 449496A1 AT bellatlantic DOT net> <3B1647B8 DOT 77530B05 AT ece DOT gatech DOT edu>

Charles Wilson wrote:
> 
> But programs compiled with -mno-cygwin don't use cygwin1.dll (which contains
> newlib, which contains the stdio functions).  -mno-cygwin programs will use the
> msvcrt.dll runtime -- which has its own implementations of the stdio functions.
> Are you saying that msvcrt's version of tmpnam/tmpfile are broken?  If so,
> that's not really our problem...

I've been madly going through the actual source code in question (a
p-code compiler, so it's fairly large, and it's not mine), and begin to
suspect that it's actually bypassing tmpfile (on the grounds that some
supposedly ANSI compilers omit it) and simply forcing "/tmp".  (It
#ifdef's a wild range of targets -- compared to some of them, MS-DOS is
practically a Unix clone -- so I'm having a little difficulty being sure
of just what the code _is_ doing.)

  ***********

[Making a special case for MinGW in the #defines]

[Recompiling it]

[Yup, runs OK under Cygwin]

[And....  runs OK on the MS-DOS prompt, too]

  ************

OK, it looks like I had a false alarm.  Apologies -- unfortunately, the
code did a damn good job of simulating a C runtime problem....

-- 
John W. Kennedy
(Hoping for enough disk space soon so that I can start
 moving thoroughly to Linux and have done with everything
 with the Evil Empire's slime on it.)

--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


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