Developer Guide

Contents

Linking on IA-32 Architecture Systems

The following examples illustrate linking that uses Intel(R) compilers.
Most
examples use the
.f
Fortran source file. C/C++ users should instead specify a
.cpp
(C++) or
.c
(C) file and replace
ifort
with
icl
:
  • Static linking of
    myprog.f
    and
    OpenMP* threaded
    Intel® oneAPI Math Kernel Library
    supporting the cdecl interface
    :
    ifort myprog.f mkl_intel
    _c
    .
    lib
    mkl_intel_thread.
    lib
    mkl_core.
    lib
    l
    ib
    iomp5
    md.lib
  • Dynamic linking of
    myprog.f
    and
    OpenMP* threaded
    Intel® oneAPI Math Kernel Library
    supporting the cdecl interface
    :
    ifort myprog.f mkl_intel
    _c_dll.lib
    mkl_intel_thread
    _dll.lib
    mkl_core
    _dll.lib
    l
    ib
    iomp5
    md.lib
  • Static linking of
    myprog.f
    and sequential version of
    Intel® oneAPI Math Kernel Library
    supporting the cdecl interface
    :
    ifort myprog.f mkl_intel
    _c
    .
    lib
    mkl_sequential.
    lib
    mkl_core.
    lib
  • Dynamic linking of
    myprog.f
    and sequential version of
    Intel® oneAPI Math Kernel Library
    supporting the cdecl interface
    :
    ifort myprog.f mkl_intel
    _c_dll.lib
    mkl_sequential
    _dll.lib
    mkl_core
    _dll.lib
  • Static linking of
    myprog.f
    , Fortran 95 LAPACK interface, and
    OpenMP* threaded
    Intel® oneAPI Math Kernel Library
    supporting the cdecl interface
    :
    ifort myprog.f mkl_lapack95
    .lib
    mkl_intel
    _c
    .
    lib
    mkl_intel_thread.
    lib
    mkl_core.
    lib
    lib
    iomp5
    md.lib
  • Static linking of
    myprog.f
    , Fortran 95 BLAS interface, and
    OpenMP* threaded
    Intel® oneAPI Math Kernel Library
    supporting the cdecl interface
    :
    ifort myprog.f mkl_blas95
    .lib
    mkl_intel
    _c
    .
    lib
    mkl_intel_thread.
    lib
    mkl_core.
    lib
    lib
    iomp5
    md.lib
  • Static linking of
    myprog.c
    and
    Intel® oneAPI Math Kernel Library
    threaded with Intel® Threading Building Blocks (Intel® TBB), provided that the
    LIB
    environment variable
    contains the path to Intel TBB library:
    icl myprog.c /link /libpath:$MKLPATH -I$MKLINCLUDE mkl_intel.lib mkl_tbb_thread.lib mkl_core.lib tbb.lib
  • Dynamic linking of
    myprog.c
    and
    Intel® oneAPI Math Kernel Library
    threaded with Intel® TBB, provided that the
    LIB
    environment variable contains the path to Intel® TBB library:
    icl myprog.c /link /libpath:$MKLPATH -I$MKLINCLUDE mkl_intel_dll.lib mkl_tbb_thread_dll.lib mkl_core_dll.lib tbb.lib

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.