user versus system environment variables

user versus system environment variables

Today I had to compile and link some CVF code probably for the first time since I installed the CVF 6.6A update on my Windows 2000 system. I installed the update from my own account because it has administrator privileges.

The link failed with the LNK1104 error for file DFORMD.LIB, but the file exists in C:Program FilesMicrosoft Visual StudioDF98LIB. I then issued the SET command at a DOS prompt and noticed that my user definition of the LIB environment variable was in effect. My user definition didn't include the ...DF98LIB directory, but the system definition of LIB did.

Looking more closely, I noticed that a number of user definitions of environment variables were overriding the corresponding system definitions.

I remember this happening once before some time ago. I cleaned up the definitions of variables manually, and I don't know how the user definitions crept back in. Does anyone know how these get set?


4 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Well, the initial values get set in My Computer..Properties..Advanced..Environment Variables. How did you start your command prompt session? Did it invoke some BAT file that defined the environment variables?


Steve - Intel Developer Support

I started my DOS sessions with Start>Programs>Accessories>Command Prompt.

I simplified my original post. I'm running an application that generates Fortran source code and then compiles, links, and runs it. All the compile and link information is buried in the code in a form that isn't very convenient to extract without a lot of work, so I won't list the information here. I believe that the application makes a call to a Windows API routine to transfer control to the new executable. I'm not aware of any batch file that the application runs to define user environment variables.

I guess I'll manually clean up the environment variable definitions again. The system definitions appear to be supersets of the user definitions, so I'll probably just delete the user definitions. I'll then watch more closely to see when the user definitions get populated again and attempt to determine if there's some kind of pattern.



Were you compiling/linking from the command prompt? If not you can use the Developer Studio Tools/Options/Directories tab to set your global includes and avoid any messing with environment variables.
If you use the command line, I guess you'll need to write a batch file to reset everything...


Leave a Comment

Please sign in to add a comment. Not a member? Join today