- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
I am trying to add some openmp to my existing code, which is a mix of fortran and C. The OPENMP calls will all be from fortran routins. I have tired to add /Qopenmp-lib:compat under Properties->Linker->Command Line but i still get:
Error 3 error LNK2019: unresolved external symbol _OMP_SET_NUM_THREADS referenced in function _MAIN__ main.obj
at the first occurance of and openmp call.
What do I have to do in the compile/link parameters??
thanks,
コピーされたリンク
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
- 新着としてマーク
- ブックマーク
- 購読
- ミュート
- RSS フィードを購読する
- ハイライト
- 印刷
- 不適切なコンテンツを報告
Hi mhovers,
You do not typically need to specify /Qopenmp-lib:compat for mixed Fortran and C code unless you are mixing OpenMP code from Intel and Native compilers in the same application. In addition, that command line argument is already the default in the version 11 compilers and beyond.
As Steve Lionel says below, the important switch you need is /Qopenmp. That switch is necessary to link in the OpenMP run-time library called libiomp5.dll. I hope this helps.
- Grant
