I am trying to compile a simple "hello world" program from the command line in Windows. However, I get this error:
> icl hello.cpp -o hello Intel(R) C++ Intel(R) 64 Compiler XE for applications running on Intel(R) 64, Version 184.108.40.206 Build 20150407 Copyright (C) 1985-2015 Intel Corporation. All rights reserved. icl: error #10114: Microsoft Visual C++ not found in path
Microsoft Visual Studio 2010 was installed along with the Intel C++/Fortran compilers. The Fortran compiler works fine. What am I doing wrong?
The compiler driver needs to know the path to the MS Visual C++ executable so as to emulate the version for compatibility per-se. Make sure to edit your PATH environment variable to include the directories where the cl.exe is found in addition to the path to the header files and run time libs as well. Just running the visual c++ vcvars32.bat file should set the required paths as well.
I'm not sure where to find the cl.exe and vcvars32.bat files.
Do I need to install Visual Studio Express, in addition to the version that comes with the compilers? Another thread suggested doing this, but it did not seem to be the final solution.
Visual studio community 2013 or 2015 are better choices, if you qualify. Express doesn't support icl GUI, debug, nor 64 bit mode.
I would recommend 2015 except that it takes longer and tends to make incomplete automatic upgrades which can invalidate install paths.
If you have kept the expanded lcl install files, you can remove icl, install vs, then run icl install from the download.
Pardon the delay in responding and thanks to Tim in letting you know that Express Edition is not supported. Also, the Intel compiler is compatible with Microsoft* Visual Studio* 2010, 2012, and 2013 and 2010 is actually deprecated in the upcoming 2016 version as well and the beta for that version ended just last month.
That said, if during installation you had integrated with the required VS version (say 2010 for example), then by just bringing up Intel C++ command line window from the start menu for the product under Compiler and Performance Libraries->Command Prompt With Intel Compiler" would automatically set the necessary variables and you do not need run the compilervars.bat file at all like you mentioned in your response when trying the solution in the other forum thread. Otherwise, you can run the compilervars.bat with arguments to it such as the architecture (ia32 or ia32_intel64) and the MS VS version such as vs2010, vs2013 etc. That should set the necessary environment variables as well.
BTW, to your question earlier you can use the where command to get the path to the file like below:
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64\vcvarsx86_a
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\vcvars32.bat
Hope that helps. When you try to install the product ensure you select the correct visual studio version before proceeding so the compiler is properly integrated with that version. You can then bring up the Intel C++ command line window to verify as well.
Got it, thanks for letting me know Jeff. Hope you'll pursue evaluating icl in the near future (BTW, the next major version 2016 will be released soon) appreciate much.