- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Linking...
LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
libguide40.lib(kmp_ftn_stdcall_import.lobj) : error LNK2019: unresolved external symbol _kmp_set_library_gang referenced in function _KMP_SET_LIBRARY_GANG@0
Debug/HelloWorldOpenMP.exe : fatal error LNK1120: 1 unresolved external
This type of linking error happens with all Fortran-External Procedures-Calling Conventions, but the C, REFERENCE flag. Anyway, I wonder if the error I get is because the libraries we have are not up to date, or for some reason the /iface:CVF flag is not compatible with the /Qopenmp compiler flag.
We want to parallelize out power systems applications, most of the code is in FORTRAN, but we also use C and C++ to implemet some parts of our system. I think that this is the reason why in our build procedures we need to have the /iface:cvf flag set.
For completeness I have attached a small HelloWorld program where this happens (though I think it is not needed to reproduce this problem).
I appreciate any help with this issue.
Thanks,
Carlos
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks Henry for your reply,
From theHelp-About menu:
Intel Fortran Compiler Integration for Microsoft Visual Studio .NET 2003, Version 8.0.1877.2003
I have the following options set for the HelloOMP program:
/nologo /Zi /Od /Qopenmp /iface:cvf /module:"Debug/" /object:"Debug/" /traceback /check:bounds /libs:static /dbglibs /c
------ Build started: Project: HelloWorldOpenMP, Configuration: Debug Win32 ------
Compiling...
HelloWorldOpenMP.f90
ifort: Command line warning: openmp requires C style preprocessing; using fpp to preprocess
Linking...
LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
libguide40.lib(kmp_ftn_stdcall_import.lobj) : error LNK2019: unresolved external symbol _kmp_set_library_gang referenced in function _KMP_SET_LIBRARY_GANG@0
Debug/HelloWorldOpenMP.exe : fatal error LNK1120: 1 unresolved externals
Build log written to file://D:userscazHelloWorldOpenMPHelloWorldOpenMPDebugBuildLog.txt
HelloWorldOpenMP build failed.
---------------------- Done ----------------------
Build: 0 succeeded, 1 failed, 0 skipped
1.- With the /iface:stdref flag
------ Build started: Project: HelloWorldOpenMP, Configuration: Debug Win32 ------
Compiling...
HelloWorldOpenMP.f90
ifort: Command line warning: openmp requires C style preprocessing; using fpp to preprocess
Linking...
HelloWorldOpenMP.obj : error LNK2019: unresolved external symbol _omp_get_max_threads@0 referenced in function _main__
HelloWorldOpenMP.obj : error LNK2019: unresolved external symbol _omp_get_thread_num@0 referenced in function ___main__
libifcoremt.lib(libifcoremain.obj) : error LNK2019: unresolved external symbol _MAIN__ referenced in function _main
Debug/HelloWorldOpenMP.exe : fatal error LNK1120: 3 unresolved externals
Build log written to file://D:userscazHelloWorldOpenMPHelloWorldOpenMPDebugBuildLog.txt
HelloWorldOpenMP build failed.
---------------------- Done ----------------------
Build: 0 succeeded, 1 failed, 0 skipped
As I said before, this problem may be related to the library versions that we have.
Thanks again,
Carlos
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page