Community
cancel
Showing results for 
Search instead for 
Did you mean: 
S__MPay
Beginner
65 Views

MKL link2019 error when using Release mode

When I compile my code using Debug mode it is build successfully but when I try the Release mode I get linking error.

I am using some MKL functions:

1>RBUS.obj : error LNK2019: unresolved external symbol DGETRF referenced in function CLASS_STIFFNESS_mp_STIFFNESS_INVERSEK
1>RBUS.obj : error LNK2019: unresolved external symbol DGETRI referenced in function CLASS_STIFFNESS_mp_STIFFNESS_INVERSEK
1>RBUS.obj : error LNK2019: unresolved external symbol DPOSV referenced in function MDLSOLVER_mp_MKLSYMSOL
1>RBUS.obj : error LNK2019: unresolved external symbol DGESV referenced in function MDLSOLVER_mp_MKLSOLVE
1>RBUS.obj : error LNK2019: unresolved external symbol DGETRS referenced in function MDLSOLVER_mp_MKLSOLVEFACT
1>x64\Release\RBUS.exe : fatal error LNK1120: 5 unresolved externals

I could not figure out why this is happening.

0 Kudos
1 Reply
S__MPay
Beginner
65 Views

I noticed that project properties for Debug mode and release mode are saved separately.

So I followed automatic linking procedure:

Project>[Project Name] Properties>Configuration Properties>Fortran>Libraries>Use Intel Math Kernel Library and select Parallel, Sequential, or Cluster as appropriate.

and this resolved the issue.

I hope someone will find this topic useful.