Date: Thu, 02 Jan 2003 20:23:07 +0300 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: djgpp AT delorie DOT com Message-Id: <7458-Thu02Jan2003202306+0200-eliz@is.elta.co.il> X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 1.8.9 CC: rich AT phekda DOT freeserve DOT co DOT uk In-reply-to: <3E14606E.E5B4D1A9@phekda.freeserve.co.uk> (message from Richard Dawe on Thu, 02 Jan 2003 15:53:18 +0000) Subject: Re: Handling of TMPDIR, TEMP by various DJGPP programs References: <3E14606E DOT E5B4D1A9 AT phekda DOT freeserve DOT co DOT uk> Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > Date: Thu, 02 Jan 2003 15:53:18 +0000 > From: Richard Dawe > > $TMPDIR seems to have different slash directions, depending on which program I > use: > > bash-2.04$ echo | awk "{ print ENVIRON[\"TMPDIR\"] }" > c:\temp > bash-2.04$ perl -e 'print $ENV{TMPDIR}."\n";' > c:\temp > bash-2.04$ sh -c 'echo $TMPDIR' > c:/temp TMPDIR should have forward slashes by virtue of DJGPP.ENV, unless TMPDIR is already set outside the DJGPP program you run (gawk and Bash in these cases). > I suspect the programs are working as expected, but it's a bit confusing when > you have, say, Perl and shell script programs interacting. I wonder if TMPDIR > should be forward-slashified in awk & perl, like it is in bash. Bash _must_ have TMPDIR forward-slashed, or else lots of scripts will fall apart. I don't know about Perl, but I think you are right assuming it should get the same treatment. As for TEMP, I don't think Unix programs use it, so it could be left at its backslashed form.