|
If you have multiple versions of Microsoft Visual Studio* installed on your system, the Intel® C++ and Fortran Compilers for Windows* install command-line support for one version only (chosen during installation). If you need command-line support for other installed versions of Visual Studio, use the method described here.
Let's start by assuming you installed the Intel® C++ Compiler 9.1 for Windows* with command line support for Microsoft Visual Studio 2005 on a system that also has Microsoft Visual Studio .NET 2003. This implies that the Windows Start Menu for the Intel C++ Compiler includes the Build Environment for IA-32 Applications. Clicking this menu item opens a command window set up to run the Intel C++ Compiler from the command line using the linker, runtime include files, and runtime libraries that come with Microsoft Visual Studio 2005.
If you need command-line support for both versions of Visual Studio, follow these steps:
- A default installation of the Intel C++ Compiler 9.1 places the IA-32 binaries in: C:\Program Files\Intel\Compiler\C++\9.1\IA32\Bin. In this directory, copy iclvars.bat to my_vs2005.bat and to my_vs2003.bat.
- Also in this directory, copy icl.cfg to my_vs2005.cfg and to my_vs2003.cfg.
- Open my_vs2005.bat and add this line to the end of the file:
SET ICLCFG=%ICPP_COMPILER91%\IA32\bin\my_vs2005.cfg
- Open my_vs2003.bat and make these changes:
Replace: @call " C: \Program Files\Microsoft Visual Studio 8\VC\Bin\Vcvars32.bat" with: @call " C: \Program Files\Microsoft Visual Studio .NET 2003\VC7\Bin\Vcvars32.bat" (this example assumes default installations for Visual Studio) Add this line at the end: SET ICLCFG=%ICPP_COMPILER91%\IA32\bin\my_vs2003.cfg
- Open my_vs2003.cfg and make these changes:
Replace: -Qvc8 with -Qvc7.1 Replace: -Qlocation,link," C: \Program Files\Microsoft Visual Studio 8\VC\Bin" with: -Qlocation,link," C: \Program Files\Microsoft Visual Studio .NET 2003\VC7\Bin" You can then use my_vs2005.bat and my_vs2003.bat to set up the appropriate environment at the command line. It is recommended that you only use these once per command shell, as the PATH environment variable may fill completely if these are used too often in the same shell. Optionally, you can also add corresponding command consoles to you Start Menu.
Do the following:
- Go to the C:\Documents and Settings\All Users\Start Menu\Programs\Intel(R) Software Development Tools\Intel(R) C++ Compiler 9.1 directory
- Copy the Build Environment for IA-32 applications shortcut to something with a different and descriptive name, like Build Environment for IA-32 applications on VS 2005
- Right-click on Build Environment for IA-32 applications on VS 2005 and select Properties.
- Change the target:
from C:\WINNT\system32\cmd.exe /K "" C: \Program Files\Intel\Compiler\C++\9.1\IA32\Bin\iclvars.bat"" to C:\WINNT\system32\cmd.exe /K "" C: \Program Files\Intel\Compiler\C++\9.1\IA32\Bin\my_vs2005.bat""
- Repeat as needed
Paths will change depending on the versions of the Intel compilers and Microsoft compilers you are working with, as well as whether you're using the Intel C++ or Fortran compiler (make special note that the environment variable for pointing to the configuration file on Fortran is IFORTCFG, not ICLCFG), but the underlying steps should still apply. Please refer to the Intel compiler release notes for which versions of Microsoft's compilers are supported.
This applies to:
|