Mail Archives: djgpp/2002/12/17/11:45:22
Wilfried Hennings <nospam AT fz-juelich DOT de> wrote in
news:8gvtvuo1qe2qi661n15lf6u1vt69ar7d5j AT 4ax DOT com:
> Right click on "My computer" on your desktop, then "properties",
> "extended" (or what else is it in English? I have the German WinXP),
it is "Advanced" in the English version.
> "environment variables".
> There I (logged in with admin rights) see two sets of variables:
> User variables and system variables.
> "TEMP=C:\DOCUME~1\asu1\LOCALS~1\Temp" comes from the user variables.
> "TEMP=c:\windows\temp" comes from the system variables.
Yes, I know that.
> If I open a command prompt, I get the "user" temp.
> But if the djgpp program opens a new process, what variables does this
> get??? I don't know! And I myself would like to be a little bit more
> enlighted in this respect...
I got curious and checked the sources. The code in crt1.c does not give
any immediate clues. I suspect most of the work is being done in
stub.asm but I am not well versed in the technicalities of PSP's etc and
x86 assembly language.
I thought maybe variables from my user environment settings were not seen
by the djgpp stub code, but they are. I verified this by compiling and
running a program that displayed the value of a variable that is only
defined in the user environment.
My guess at this point is that this maybe a bug in ntvdm or whatever
deals with setting up the PSP etc for dos programs in Win XP.
I made the following changes to my djgpp.env as a work-around:
+TMPDIR=C:\DOCUME~1\%USERNAME%\LOCALS~1\Temp
TEMP=%TMPDIR%
TMP=%TMPDIR%
--
A. Sinan Unur
asu1 AT c-o-r-n-e-l-l DOT edu
Remove dashes for address
Spam bait: mailto:uce AT ftc DOT gov
- Raw text -