Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
28446 Discussions

Fortran 14.1 command prompt redefining environment variable COMMONPROGRAMFILES

Greg_S_3
Beginner
377 Views

Has anyone noticed an issue with the intel 14.1 command prompt (either 32 or 64 bit) and having the COMMONPROGRAMFILES environment variable changed from the windows default (C:\Program Files\Common Files) to C:\Program Files (x86)\Common Files?  If a try to run some other software that uses the default environment variable from the intel prompt it does not function and I must switch to another prompt that does not support the fortran.  So on my system I have the following set by default

>echo %COMMONPROGRAMFILES%
C:\Program Files\Common Files

>echo %COMMONPROGRAMFILES(X86)%
C:\Program Files (x86)\Common Files

But, while on the intel prompt it changes it to 

>echo %COMMONPROGRAMFILES%
C:\Program Files (x86)\Common Files

>echo %COMMONPROGRAMFILES(X86)%
C:\Program Files (x86)\Common Files

Is this correct or is there something wrong with my install?  Is there a work around?  Any help would be appreciated.  I would like to return to the times when I had a single command prompt with the environment always set for both intel fortran and all my other codes

0 Kudos
3 Replies
Steven_L_Intel1
Employee
377 Views

Windows is doing this. See http://www.viva64.com/en/k/0020/ and https://support.microsoft.com/en-us/kb/950407 

0 Kudos
Greg_S_3
Beginner
377 Views

Steve - thanks for the quick reply.  I guess everything is just getting much more complicated.  The Fortran works great and my other software works well as long as I do not try to run from the Intel prompt.  I will try some of the fixes that are suggested in your links though I'm still not sure that I can actually get back to a single prompt that will support everything.  Thanks again.

0 Kudos
Steven_L_Intel1
Employee
377 Views

I didn't look at the suggested "fixes". I note that Microsoft Visual Studio's command prompt does the same thing and, as with Intel Fortran, there is nothing in the scripts themselves that change this. I guess it has to do with the use of C:\Windows\SysWOW64\cmd.exe to start the command line. If you use the one in C:\Windows\System32 instead, then you get the 64-bit one and Windows doesn't change the variable. I'm not sure why one would choose one over the other.

0 Kudos
Reply