my problem is that I want to invoke the icc compiler from the commandline, but my pc can't find it. I have install the latest oneAPI and sourced setvars.sh.
Even I search 'icc' file under the installation routine I can't find the icc compiler file.
'which' command works for mpicc and dpcpp but not for icc can not find icc/// mpicc found but not icc
In order to use Intel C compiler and Intel Fortran compiler for numerical computation, Intel oneAPI Base Toolkit and HPC Toolkit (Intel Fortran) on Ubuntu 20.04 LTS of WSL2 of Windows 10 Pro were installed. This site (in Japanese) was referred.
Open /Home, Press Ctrl+H to show hidden files, there will be file named .bashrc open it using any editor you like. now compile your C code using icc commands. It will compile with icc compiler. now compile your C code using icc commands.
Intel® C++ Compiler Classic is included as part of the Intel® oneAPI HPC and IoT Toolkits. Use the following command to invoke the classic compiler from the command line: For C/C++ source files: {icc|icpc} [options] file1 [file2...] For more information about invoking the Intel® C++ Classic compiler, see Invoking the Compiler
Intel C++ Compiler <major.minor> (example 19.2) to invoke icl Alternatively, you can specify a compiler version as the toolset for all supported platforms and configurations of the selected project(s) by selecting Project > Intel Compiler > Use Intel oneAPI DPC++/C++ Compiler
It looks like you might have installed Intel OneAPI base toolkit. The icc compiler is not a part of the base toolkit. To get icc(Intel® C++ Compiler Classic) you should install Intel OneAPI HPC toolkit. Below is a link to HPC toolkit. You would see icc in the "whats included" section
https://software.intel.com/content/www/us/en/develop/tools/oneapi/hpc-toolkit.html
You could install hpc toolkit on the top of your basekit, it installs only whatever is not present as a part of base toolkit.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With