Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.
7276 Discussions

Help..How to link LAPACK within MKL10.0.011 correctly?

cyfeng
Beginner
1,182 Views

I tried to use the function getrf in my FORTRAN program in the Microsoft Visual Studio 2005 on the Windows XP like this:

call getrf(MATRIX_A)

I had include the file "MKL_LAPACK.F90" and use the modules MKL95_PRECISION and MKL95_LAPACK. However, I got the error message while compiling the program: error LNK:2019 unresolved external symbol _DGETRF_MKL95 and I noticed there is a pure subroutine named DGETRF_MKL95 within the module MKL95_LAPACK in the file "MKL_LAPACK.F90". Did I miss anything? Thank you..

0 Kudos
2 Replies
cyfeng
Beginner
1,182 Views

Hiall,

I know what I lost.. and would like to share the experience with others. First, please refer to the followingpost: http://software.intel.com/en-us/forums//topic/49009 orChap 7on the "Inter Math Kernel Library for Windows* User's Guide".

All that we need to do is to build corresponding libraries. But...how?

Find the iterm fromwindows program menu:"Intel Software Development ToolsIntel Fortran Compiler 10.1.011" andclick the "Intel Fortran Compiler for applications running on IA-32". Then the cmd window popped up. Change the directory to the one containing the source files,C:Program FilesIntelMKL10.0.xxxinterfaceslas95, say. Type the following: nmake PLAT=win32 lib. The mkl95_blas.mod and mkl95_precision.mod will be created andcopied to the ....ia32lib. The modules mkl95_precision.mod and mkl95_lapack.mod were created similarly.

0 Kudos
Vladimir_Koldakov__I
New Contributor III
1,182 Views

Hello, CYFeng,

You can also enter the directory exampleslas95 or exampleslapack95 and run examples: nmake lib32.

As a result, the required library (mkl95_blas.lib or mkl95_lapack.lib) and a respective .mod file will be built and installed in the standard catalog of the release. Of course, you have to link built library.

-Vladimir

0 Kudos
Reply