Developer Guide for Intel® oneAPI Math Kernel Library for Windows*
Examples for Linking a C Application
These examples illustrate linking of an application under the following conditions:
Main module is in C.
You are using the Intel ® oneAPI DPC++/C++ Compiler.
Intel ® MPI Library is installed in C:\Program Files(x86)\Intel\oneAPI\mpi. Instructions on how to install Intel ® MPI Library can be found on the Get Started with Intel® MPI Library for Windows* OS and Intel® oneAPI Toolkits Installation Guide for Windows* pages.
Intel® oneAPI Math Kernel Library (oneMKL) functions use LP64 interfaces.
The PATH environment variable contains a directory with the MPI linker scripts.
$MKLPATH is a user-defined variable containing <mkl_directory>\lib.
To set the Intel ® MPI Library environment, you must run the <path to Intel oneAPI installation>\env\*vars.bat script.
To link with ScaLAPACK for a cluster of Intel ® 64 architecture based systems, set the environment variable and use the link line as follows:
set lib=<mkl directory>\lib;%lib%
icx <user files to link> mkl_scalapack_lp64.lib blacs_intelmpi_lp64.lib mkl_intel_lp64.lib mkl_intel_thread.lib mkl_core.lib libiomp5md.lib impi.lib bufferoverflowu.lib
To link with Cluster FFT for a cluster of Intel ® 64 architecture based systems, set the environment variable and use the link line as follows:
set lib=<mkl directory>\lib;%lib%
icx <user files to link> mkl_cdft_core.lib mkl_blacs_intelmpi_lp64.lib mkl_intel_lp64.lib mkl_intel_thread.lib mkl_core.lib libiomp5md.lib impi.lib bufferoverflowu.lib
To link with Cluster Sparse Solver for a cluster of Intel ® 64 architecture based systems, set the environment variable and use the link line as follows:
set lib=<mkl directory>\lib;%lib%
icx <user files to link> mkl_blacs_intelmpi_lp64.lib mkl_intel_lp64.lib mkl_intel_thread.lib mkl_core.lib libiomp5md.lib impi.lib bufferoverflowu.lib