This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: patch text mode problem with latest CVS source

On Fri, Nov 03, 2000 at 09:08:57AM -0500, Jason Tishler wrote:
>On Thu, Nov 02, 2000 at 05:14:51PM -0500, Christopher Faylor wrote:
>> It seems to be controlled by the value of your "TMP" (or possibly
>> "TEMP") environment variable.  If that is set to a directory that is
>> mounted as text, then the resulting file has \r\n line endings.
>Diff-ing cygcheck outputs between 1.1.4 and 1.1.5-3, I determined
>exactly what is the root cause.  I had my TMP variable set as follows:
>    export TMP=$SYSTEMDRIVE\\tmp
>just in case some Windows programs were using this variable.  In 1.1.4,
>the TMP (and TEMP) environment variable was automagically converted
>into a POSIX style path, while in 1.1.5-3 it remained unchanged.  Hence,
>I was bitten by the unmounted drives defaulting to text mode feature.

Cygwin now passes on exactly what was set in the environment and in the
argv list.  Translation to UNIX format only happens in the first cygwin
process that is run.  Children of this process receive whatever the user

So, after the first translation, Cygwin emulates UNIX exactly.

However, if you do something like:

export TMP=/cygdrive/c/tmp

A non-cygwin Windows app will see TMP as "c:\tmp", so there should be no
reason to use Windows path specs when setting TMP environment variables.


Want to unsubscribe from this list?
Send a message to

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]