Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29253 Discussions

Link error in IVF 11.0 for the program with OpenMP

Zhanghong_T_
Novice
627 Views

Dear all,

I have a program with OpenMP compiled by IVF 11.0 in Windows XP x64 + VS.net 2005. The following errors disappeared:

2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol KMP_UNSET_AFFINITY_MASK_PROC
2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol KMP_SET_AFFINITY_MASK_PROC
2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol KMP_DESTROY_AFFINITY_MASK
2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol KMP_CREATE_AFFINITY_MASK
2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol OMP_GET_SCHEDULE
2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol OMP_SET_SCHEDULE
2>test2.lib(test2.obj) : error LNK2001: unresolved external symbol OMP_SET_MAX_ACTIVE_LEVELS

The program works for the version before IVF 11.0. Could anyone tell me what should I set for the project?

Thanks,

Zhanghong Tang

0 Kudos
2 Replies
Steven_L_Intel1
Employee
627 Views

Please show all the compiler options used to compile the sources and to link the program. The default in 11.0 is to use the new "compatibility" OpenMP library and to link against the DLL form of the OpenMP libraries. Most applications should not need to change but perhaps your project needs adjusting.

0 Kudos
Zhanghong_T_
Novice
627 Views

Please show all the compiler options used to compile the sources and to link the program. The default in 11.0 is to use the new "compatibility" OpenMP library and to link against the DLL form of the OpenMP libraries. Most applications should not need to change but perhaps your project needs adjusting.

Dear Steve,

Thank you very much for your kindly reply. Now the problem is solved, it is not the problem of project settings. It works after I replaced the "include 'omp_lib.h'" by "use omp_lib".

Thanks,

Zhanghong Tang

0 Kudos
Reply